Closed rlamorea closed 8 years ago
+1, just found this out as well.
Thanks for the feedback. I'll try to fix it this evening :)
Fixed in v0.2.3, thanks for your accurate comments.
Thanks! (And minor thing: the bower.json
still shows version as 0.2.2
)
You are not able to turn
off
a handler due to a bug on line 45:44 for (i = listeners.length - 1; i >= 0; i--) { 45 if( listeners[i] === listener ) 46 listeners.splice( i, 1 ); 47 }
Since the handler is pushed in as
{ callback: listener, once: once }
the check needs to be forlisteners[i].callback
.