mirror of
https://github.com/ZeppelinBot/Zeppelin.git
synced 2025-05-10 04:25:01 +00:00
fix: fix errors when unloading certain plugins after beforeLoad but before afterLoad
This commit is contained in:
parent
4f811f04e1
commit
f92ee9ba4f
5 changed files with 22 additions and 10 deletions
|
@ -216,7 +216,7 @@ export const ModActionsPlugin = zeppelinGuildPlugin<ModActionsPluginType>()({
|
|||
|
||||
beforeUnload(pluginData) {
|
||||
pluginData.state.unloaded = true;
|
||||
pluginData.state.unregisterGuildEventListener();
|
||||
pluginData.state.unregisterGuildEventListener?.();
|
||||
pluginData.state.events.removeAllListeners();
|
||||
},
|
||||
});
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue