Skip to content

Commit

Permalink
update events
Browse files Browse the repository at this point in the history
  • Loading branch information
penggy committed Aug 11, 2018
1 parent 22d7a9f commit 66b55fc
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions events/events.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ type EventListener struct {
HandleFunc func(...interface{}) bool
}

func NewEventListener(name string, f func(...interface{}) bool) (el *EventListener) {
func NewListener(name string, f func(...interface{}) bool) (el *EventListener) {
el = &EventListener{
Name: name,
HandleFunc: f,
Expand All @@ -20,7 +20,7 @@ type EventDispatcher struct {
listenersLock *sync.RWMutex
}

func NewEventDispatcher() (ed *EventDispatcher) {
func NewDispatcher() (ed *EventDispatcher) {
ed = &EventDispatcher{
listeners: make(map[*EventListener]bool),
listenersLock: &sync.RWMutex{},
Expand Down

0 comments on commit 66b55fc

Please sign in to comment.