Skip to content

Instantly share code, notes, and snippets.

@kmaglione
Created August 5, 2016 18:10
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save kmaglione/7a1ca656a5171f3956882a4c3f952bda to your computer and use it in GitHub Desktop.
Save kmaglione/7a1ca656a5171f3956882a4c3f952bda to your computer and use it in GitHub Desktop.
18:12 <@John-Galt> rhelmer: One fires synchronously, the other does not.
18:14 <@John-Galt> rhelmer: Also, EventManager clones arguments into the correct scope, and catches exceptions, but SingletonEventManager doesn't.
18:15 <@John-Galt> rhelmer: And there can be more than one listener at the same time, but you're setting extension.upgrade to null in your unregister function, which seems not ideal in the case of SingletonEventManager.
18:15 <@John-Galt> Or in the case of other event managers when multiple contexts are active.
18:17 <@John-Galt> So you should probably store it for the current context and not use SingletonEventManager.
18:34 <@John-Galt> Or just not set it to null.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment