mirror of
https://github.com/myned/modufur.git
synced 2024-12-24 14:27:27 +00:00
Fix bot exiting on NotFound errors within on_command_error
This commit is contained in:
parent
6ebd93ea14
commit
82fb640fc1
1 changed files with 30 additions and 29 deletions
|
@ -159,6 +159,7 @@ async def on_error(error, *args, **kwargs):
|
|||
|
||||
@bot.event
|
||||
async def on_command_error(ctx, error):
|
||||
with suppress(err.NotFound):
|
||||
if isinstance(error, errext.CommandOnCooldown):
|
||||
await ctx.message.add_reaction('\N{HOURGLASS}')
|
||||
await asyncio.sleep(error.retry_after)
|
||||
|
|
Loading…
Reference in a new issue