Update ModuleManager.load_module calls in modules.py

This commit is contained in:
jesopo 2018-09-29 09:23:57 +01:00
parent 0f7a122a84
commit 7c7e5553d1

View file

@ -11,7 +11,7 @@ class Module(ModuleManager.BaseModule):
if name in self.bot.modules.modules: if name in self.bot.modules.modules:
event["stderr"].write("Module '%s' is already loaded" % name) event["stderr"].write("Module '%s' is already loaded" % name)
return return
self.bot.modules.load_module(name) self.bot.modules.load_module(self.bot, name)
event["stdout"].write("Loaded '%s'" % name) event["stdout"].write("Loaded '%s'" % name)
@Utils.hook("received.command.unloadmodule", min_args=1, @Utils.hook("received.command.unloadmodule", min_args=1,
@ -29,7 +29,7 @@ class Module(ModuleManager.BaseModule):
def _reload(self, name): def _reload(self, name):
self.bot.modules.unload_module(name) self.bot.modules.unload_module(name)
self.bot.modules.load_module(name) self.bot.modules.load_module(self.bot, name)
@Utils.hook("received.command.reloadmodule", min_args=1, @Utils.hook("received.command.reloadmodule", min_args=1,
permission="reload-module", usage="<module-name>") permission="reload-module", usage="<module-name>")