mirror of
https://github.com/Mikaela/Limnoria.git
synced 2024-12-24 11:42:52 +01:00
ChannelStats: Don't crash on messages with no argument, eg. AWAY.
This commit is contained in:
parent
10522857b1
commit
65abedcca1
@ -142,7 +142,7 @@ class StatsDB(plugins.ChannelUserDB):
|
||||
return UserStat(*L)
|
||||
|
||||
def addMsg(self, msg, id=None):
|
||||
if ircutils.isChannel(msg.args[0]):
|
||||
if msg.args and ircutils.isChannel(msg.args[0]):
|
||||
channel = plugins.getChannel(msg.args[0])
|
||||
if (channel, 'channelStats') not in self:
|
||||
self[channel, 'channelStats'] = ChannelStat()
|
||||
|
Loading…
Reference in New Issue
Block a user