summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xminiircd4
1 files changed, 3 insertions, 1 deletions
diff --git a/miniircd b/miniircd
index f4c98cd..74f1fc6 100755
--- a/miniircd
+++ b/miniircd
@@ -196,7 +196,9 @@ class Client(object):
self.reply_403(channelname)
continue
channel = server.get_channel(channelname)
- if channel and channel.key != keys[i]:
+ if channel \
+ and channel.key is not None \
+ and channel.key != keys[i]:
self.reply(
"475 %s %s :Cannot join channel (+k) - bad key"
% (self.nickname, channelname))