3
0
mirror of https://github.com/jlu5/PyLink.git synced 2024-11-24 03:29:28 +01:00

pr/insp: don't crash when a server sends TOPIC

This commit is contained in:
James Lu 2015-07-15 19:08:36 -07:00
parent c22c187717
commit 798476c850

View File

@ -641,9 +641,8 @@ def handle_topic(irc, numeric, command, args):
channel = args[0].lower() channel = args[0].lower()
topic = args[1] topic = args[1]
ts = int(time.time()) ts = int(time.time())
setter = irc.users[numeric].nick
irc.channels[channel].topic = topic irc.channels[channel].topic = topic
return {'channel': channel, 'setter': setter, 'ts': ts, 'topic': topic} return {'channel': channel, 'setter': numeric, 'ts': ts, 'topic': topic}
def handle_invite(irc, numeric, command, args): def handle_invite(irc, numeric, command, args):
# <- :70MAAAAAC INVITE 0ALAAAAAA #blah 0 # <- :70MAAAAAC INVITE 0ALAAAAAA #blah 0