mirror of
https://github.com/Mikaela/Limnoria.git
synced 2024-11-23 19:19:32 +01:00
Don't try to kick people that aren't in the channel.
This commit is contained in:
parent
edf7af7711
commit
eff7489469
@ -268,6 +268,9 @@ class Channel(callbacks.Privmsg):
|
||||
"""
|
||||
if self.haveOps(irc, channel, 'kick someone'):
|
||||
(nick, reason) = privmsgs.getArgs(args, optional=1)
|
||||
if nick not in irc.channels[channel].users:
|
||||
irc.error('%s isn\'t in %s.' % (nick, channel))
|
||||
return
|
||||
if not reason:
|
||||
reason = msg.nick
|
||||
irc.queueMsg(ircmsgs.kick(channel, nick, reason))
|
||||
|
Loading…
Reference in New Issue
Block a user