You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
cb may not be a function depending on how the async-exit-hook routine is entered. If it's entered with an uncaught error, then it's called with 2 params and the second is the callback.
if(exit&&hook.length>syncArgCount){// Hook is async, expects a finish callbackwaitingFor++;if(err){// Pass error, calling uncaught exception handlersreturnhook(err,stepTowardExit);// call called with 2 params}returnhook(stepTowardExit);// <-- called with 1 param}
This would be easy to fix by simply changing the second to:
returnhook(null,stepTowardExit);
Because this is a breaking change to the API, it probably warrants a major version upgrade.
The text was updated successfully, but these errors were encountered:
When calling exit hook, like so:
cb
may not be a function depending on how theasync-exit-hook
routine is entered. If it's entered with an uncaught error, then it's called with 2 params and the second is the callback.This would be easy to fix by simply changing the second to:
Because this is a breaking change to the API, it probably warrants a major version upgrade.
The text was updated successfully, but these errors were encountered: