mirror of
https://github.com/Mikaela/Limnoria.git
synced 2025-03-29 10:56:57 +01:00
Reject invalid join commands outright.
This commit is contained in:
parent
ec8d1bef06
commit
6ebc226e00
@ -137,6 +137,8 @@ class Admin(privmsgs.CapabilityCheckingPrivmsg):
|
|||||||
channel name via a comma. I.e., if you need to join both #a and #b,
|
channel name via a comma. I.e., if you need to join both #a and #b,
|
||||||
and #a requires a key of 'aRocks', then you'd call 'join #a,aRocks #b'
|
and #a requires a key of 'aRocks', then you'd call 'join #a,aRocks #b'
|
||||||
"""
|
"""
|
||||||
|
if not args:
|
||||||
|
raise callbacks.ArgumentError
|
||||||
keys = []
|
keys = []
|
||||||
channels = []
|
channels = []
|
||||||
for channel in args:
|
for channel in args:
|
||||||
@ -191,7 +193,7 @@ class Admin(privmsgs.CapabilityCheckingPrivmsg):
|
|||||||
you give it.
|
you give it.
|
||||||
"""
|
"""
|
||||||
if not args:
|
if not args:
|
||||||
args.append(msg.args[0])
|
args = [msg.args[0]]
|
||||||
for arg in args:
|
for arg in args:
|
||||||
if arg not in irc.state.channels:
|
if arg not in irc.state.channels:
|
||||||
irc.error('I\'m not currently in %s' % arg)
|
irc.error('I\'m not currently in %s' % arg)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user