mirror of
https://github.com/plexusorg/Plex.git
synced 2024-12-22 17:17:37 +00:00
Fix errors when unloading modules with listeners
This commit is contained in:
parent
06e51926be
commit
d7cbbc8d52
@ -110,7 +110,7 @@ public class ModuleManager
|
||||
Plex.get().getServer().getCommandMap().getKnownCommands().remove(plexCommand.getName());
|
||||
plexCommand.getAliases().forEach(alias -> Plex.get().getServer().getCommandMap().getKnownCommands().remove(alias));
|
||||
});
|
||||
module.getListeners().forEach(module::unregisterListener);
|
||||
module.getListeners().stream().toList().forEach(module::unregisterListener);
|
||||
module.disable();
|
||||
});
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user