From 25ec351d4d85f79736e31359957e803d4e55296d Mon Sep 17 00:00:00 2001 From: jesopo Date: Wed, 25 Sep 2019 12:33:12 +0100 Subject: [PATCH] show alias of disconnected server when it's a cancelled timer --- modules/admin.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/modules/admin.py b/modules/admin.py index 4d4250bc..0fb16600 100644 --- a/modules/admin.py +++ b/modules/admin.py @@ -80,14 +80,17 @@ class Module(ModuleManager.BaseModule): :permission: disconnect """ id = event["server"].id + alias = event["server"].alias if event["args"]: - alias = event["args"] + alias = event["args_split"][0] id = self.bot.database.servers.get_by_alias(alias) if id == None: raise utils.EventError("Unknown server alias") server = self.bot.get_server_by_id(id) + alias = None if not server == None: + alias = str(server) server.disconnect() self.bot.disconnect(server) elif id in self.bot.reconnections: