Correct how to handle when permissions are missing
This commit is contained in:
parent
549f72d660
commit
60cf454122
|
@ -40,7 +40,10 @@ class Miscallaneous:
|
||||||
|
|
||||||
if command is None:
|
if command is None:
|
||||||
for cmd in utils.get_all_commands(self.bot):
|
for cmd in utils.get_all_commands(self.bot):
|
||||||
if not await cmd.can_run(ctx) or not cmd.enabled:
|
try:
|
||||||
|
if not await cmd.can_run(ctx) or not cmd.enabled:
|
||||||
|
continue
|
||||||
|
except commands.errors.MissingPermissions:
|
||||||
continue
|
continue
|
||||||
|
|
||||||
cog = cmd.cog_name
|
cog = cmd.cog_name
|
||||||
|
|
Loading…
Reference in a new issue