I know that it is a common paradigm to have a function pointer passed to a removeListener function - especially when that event can handle multiple listeners.
However, with push-notification-ios, the handler parameter to removeEventListener appears to be unused and unnecessary. I also see no other reason (such as a naming pattern) that would require this and no comments either.
I know that it is a common paradigm to have a function pointer passed to a removeListener function - especially when that event can handle multiple listeners.
However, with push-notification-ios, the
handler
parameter to removeEventListener appears to be unused and unnecessary. I also see no other reason (such as a naming pattern) that would require this and no comments either.This apparently did not just trip me up as there are issues in the issue log related to it: https://github.com/react-native-push-notification-ios/push-notification-ios/issues/10
It would be good to either accept this pull request or provide more explanation in the documentation for why this parameter is needed.