Closed johnmaguire closed 4 years ago
Can I take a look at this?
Sure @chrisfoose
I'm pretty sure we just need to add code in register()
to look at the list of callbacks assigned to that event, log an error for each one we're removing, and remove ones from the list that don't properly match the arg count.
Reopening & fixing so we have a test case for swapping event system in #165.
Currently, when attempting to register a plugin's callbacks defined via the
@event
decorator, if any callback fails (e.g. due to not having the right number of function arguments), any callbacks which haven't been registered yet will not be due to lack of exception handling inside the callback loop.