Open Notmissleo opened 4 years ago
Hello, actually it is possible internally to do this. I've implemented it as a part of #261. IMO it should be easy to make Event::addErrorCallback
public, it just need some unit tests.
Would you like to provide a PR?
Description
Is it possible for there to be a way to set a task specific onError callback function? Right now, an onError function can be set but there's no way (afaik) to limit it to a single task like before() and after().
It would be nice if onError() can be used just like before() and after() callbacks.
Basically a post-execution callback that's only called if the execution of the event (not schedule) is unsucessful.
Example
In addition to this:
It would be nice if this was supported :