From 5fed4629a612ba0e01616e61c70e03f3ce93c511 Mon Sep 17 00:00:00 2001 From: James Lu Date: Sat, 5 Mar 2016 09:42:51 -0800 Subject: [PATCH] networks: remove networks with autoconnect off in 'disconnect' Closes #162. --- plugins/networks.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/plugins/networks.py b/plugins/networks.py index 8394afe..4cbe6cd 100644 --- a/plugins/networks.py +++ b/plugins/networks.py @@ -32,6 +32,9 @@ def disconnect(irc, source, args): # Abort the connection! Simple as that. network.disconnect() + if network.serverdata["autoconnect"] < 1: # Remove networks if autoconnect is disabled. + del world.networkobjects[netname] + @utils.add_cmd def connect(irc, source, args): """