-
Notifications
You must be signed in to change notification settings - Fork 18
Open
Labels
Milestone
Description
I could not find any method in the beta that provides a way to remove a listener.. i have something like this:
RequestAllTasksListener { hadErrors ->
if (hadErrors) {
cancel(true)
} else {
download()
}
}.also {
WendyConfig.addTaskRunnerListener(it)
Wendy.shared.runTasks(null)
}And every time i need to call the function with this piece of code a listener is added.. one could say that i should only put a listener one single time, but for our needs this is not true, we need to listen to events, see if there's anything wrong and 'unsubscribe' after that..