mirror of
https://github.com/Mikaela/Limnoria.git
synced 2024-11-02 17:29:22 +01:00
src/commands: Change the rest context so that it raises an IndexError when no arguments are available.
This fixes the problem in Dunno (and any other plugin that uses plugins.ChannelIdDatabasePlugin) where calling the search command using only the getopts and no additional arguments will cause the command to fail and the help to be displayed.
This commit is contained in:
parent
772f1dd2bf
commit
17afef9c30
@ -692,7 +692,7 @@ class rest(context):
|
||||
except Exception, e:
|
||||
args[:] = original
|
||||
else:
|
||||
raise callbacks.ArgumentError
|
||||
raise IndexError
|
||||
|
||||
# additional means: Look for this (and make sure it's of this type). If
|
||||
# there are no arguments for us to check, then use our default.
|
||||
|
Loading…
Reference in New Issue
Block a user