mirror of
https://github.com/Cog-Creators/Red-DiscordBot.git
synced 2025-12-06 09:22:31 -05:00
[Downloader] Suppress NotFound errors in [p]cog update command (#5109)
* [Downloader] Suppress NotFound errors when cog update message is deleted * occurance 2
This commit is contained in:
@@ -1652,12 +1652,14 @@ class Downloader(commands.Cog):
|
||||
try:
|
||||
await ctx.bot.wait_for(event, check=pred, timeout=30)
|
||||
except asyncio.TimeoutError:
|
||||
await query.delete()
|
||||
with contextlib.suppress(discord.NotFound):
|
||||
await query.delete()
|
||||
return
|
||||
|
||||
if not pred.result:
|
||||
if can_react:
|
||||
await query.delete()
|
||||
with contextlib.suppress(discord.NotFound):
|
||||
await query.delete()
|
||||
else:
|
||||
await ctx.send(_("OK then."))
|
||||
return
|
||||
|
||||
Reference in New Issue
Block a user