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