From 709365ecf87529186f521547aa9c611bd1fd9293 Mon Sep 17 00:00:00 2001 From: jesopo Date: Sun, 10 Feb 2019 14:26:24 +0000 Subject: [PATCH] Utilise new line-tracking logic to reconnect when QUIT sends (admin.py) --- modules/admin.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/modules/admin.py b/modules/admin.py index 4406b78a..cb3d69e9 100644 --- a/modules/admin.py +++ b/modules/admin.py @@ -41,9 +41,9 @@ class Module(ModuleManager.BaseModule): :help: Reconnect to the current network :permission: reconnect """ - event["server"].send_quit("Reconnecting") - self.bot.reconnect(event["server"].id, - event["server"].connection_params) + line = event["server"].send_quit("Reconnecting") + line.on_send(lambda: self.bot.reconnect( + event["server"].id, event["server"].connection_params)) @utils.hook("received.command.connect", min_args=1) def connect(self, event):