From 84de8f100e40ec70e1f404ffac0e7fd1e845ac2c Mon Sep 17 00:00:00 2001 From: James Lu Date: Mon, 28 Dec 2015 20:27:41 -0800 Subject: [PATCH] RelayNext: fix disconnected networks causing error in 'nicks' Reported by @nathan0. --- RelayNext/plugin.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/RelayNext/plugin.py b/RelayNext/plugin.py index c815e75..77a307b 100644 --- a/RelayNext/plugin.py +++ b/RelayNext/plugin.py @@ -345,7 +345,8 @@ class RelayNext(callbacks.Plugin): channel, net = cn.split("@", 1) try: c = world.getIrc(net).state.channels[channel] - except KeyError: + except (KeyError, AttributeError): + # Unknown network or network disconnected. continue totalUsers += len(c.users) users = []