Fix filtering of unsupported umodes

Signed-off-by: James McCoy <jamessan@users.sourceforge.net>
(cherry picked from commit 3bfda3cc7a)

Signed-off-by: Daniel Folkinshteyn <nanotube@users.sourceforge.net>
This commit is contained in:
James McCoy 2011-11-06 22:20:55 -05:00 committed by Daniel Folkinshteyn
parent 865e87cf74
commit ab9365f172

View File

@ -935,7 +935,7 @@ class Irc(IrcCommandDispatcher):
if umodes[0] in '+-':
(addSub, umodes) = (umodes[0], umodes[1:])
if supported:
umodes = filter(lamda m: m in supported, umodes)
umodes = [m for m in umodes if m in supported]
umodes = ''.join(addSub, umodes)
log.info('Sending user modes to %s: %s', self.network, umodes)
self.sendMsg(ircmsgs.mode(self.nick, umodes))