1
0
Fork 0
mirror of synced 2024-06-02 18:54:33 +12:00

Checked the length of the command list to verify if a command was provided

This commit is contained in:
phxntxm 2016-07-18 18:33:07 -05:00
parent d1db6f2ec8
commit 63a040be28

View file

@ -67,7 +67,7 @@ class Mod:
async def perms(self, ctx, *command: str):
"""This command can be used to print the current allowed permissions on a specific command
This supports groups as well as subcommands; pass no argument to print a list of available permissions"""
if command is None:
if command is None or len(command) == 0:
await self.bot.say("Valid permissions are: ```{}```".format("\n".join("{}".format(i) for i in valid_perms)))
return
command = " ".join(command)