API error event handler

FFozzie12/19/2022
Hi, when I get a DiscordAPIError through the logger that starts like this:
Encountered error while handling an interaction handler run method for interaction-handler
Encountered error while handling an interaction handler run method for interaction-handler
Is there a singular event to capture these without listening to multiple events such as chatInputCommandError, commandAutocompleteInteractionError and contextMenuCommandError etc?
Solution:
there isn't but you can easily reuse code. Just import the same function in each listener and pass parameters.
Jump to solution
Solution
FFavna12/19/2022
there isn't but you can easily reuse code. Just import the same function in each listener and pass parameters.

Looking for more? Join the community!