mirror of
https://github.com/Mikaela/Limnoria.git
synced 2025-01-27 12:44:19 +01:00
Fixed possible raised KeyError.
This commit is contained in:
parent
5d45c92592
commit
9e94295d34
@ -467,8 +467,8 @@ class ChannelDB(callbacks.Privmsg,plugins.Toggleable,plugins.ChannelDBHandler):
|
|||||||
try:
|
try:
|
||||||
id = ircdb.users.getUserId(user)
|
id = ircdb.users.getUserId(user)
|
||||||
except KeyError: # Maybe it was a nick. We'll look up by hostmask.
|
except KeyError: # Maybe it was a nick. We'll look up by hostmask.
|
||||||
hostmask = irc.state.nickToHostmask(user)
|
|
||||||
try:
|
try:
|
||||||
|
hostmask = irc.state.nickToHostmask(user)
|
||||||
id = ircdb.users.getUserId(hostmask)
|
id = ircdb.users.getUserId(hostmask)
|
||||||
except KeyError:
|
except KeyError:
|
||||||
irc.error(msg, conf.replyNoUser)
|
irc.error(msg, conf.replyNoUser)
|
||||||
|
Loading…
Reference in New Issue
Block a user