1
0
Fork 0
mirror of synced 2024-05-20 20:42:27 +12:00

Added a possible exception to catch

This commit is contained in:
phxntxm 2017-03-08 00:19:42 -06:00
parent f91e992d25
commit 78187197b3
2 changed files with 2 additions and 2 deletions

View file

@ -84,7 +84,7 @@ def custom_perms(**perms):
try:
required_perm_value = server_settings['permissions'][ctx.command.qualified_name]
required_perm = discord.Permissions(required_perm_value)
except (TypeError, IndexError):
except (TypeError, IndexError, ValueError):
pass
# Now just check if the person running the command has these permissions

View file

@ -121,7 +121,7 @@ def command_prefix(bot, message):
try:
prefix = cache['server_settings'].values[message.guild.id]['prefix']
return prefix or default_prefix
except (KeyError, TypeError, IndexError, AttributeError):
except (KeyError, TypeError, IndexError, AttributeError, ValueError):
return default_prefix