mirror of
https://github.com/myned/modufur.git
synced 2024-12-25 06:37:29 +00:00
Fix errors not sending after interaction
This commit is contained in:
parent
aecb10d3f2
commit
189dc23e82
2 changed files with 5 additions and 1 deletions
|
@ -70,7 +70,11 @@ async def on_reverse_error(event):
|
||||||
error = '**An unknown SauceNAO error has occurred. The service may be down.**'
|
error = '**An unknown SauceNAO error has occurred. The service may be down.**'
|
||||||
|
|
||||||
if error:
|
if error:
|
||||||
|
try:
|
||||||
await event.context.respond(error)
|
await event.context.respond(error)
|
||||||
|
except:
|
||||||
|
await event.context.interaction.edit_initial_response(error, components=None)
|
||||||
|
|
||||||
return True
|
return True
|
||||||
|
|
||||||
async def _reverse(context, urls, *, selector=None):
|
async def _reverse(context, urls, *, selector=None):
|
||||||
|
|
2
run.py
2
run.py
|
@ -24,7 +24,7 @@ async def on_error(event):
|
||||||
try:
|
try:
|
||||||
await event.context.respond(c.ERROR)
|
await event.context.respond(c.ERROR)
|
||||||
except:
|
except:
|
||||||
pass
|
await event.context.interaction.edit_initial_response(c.ERROR, components=None)
|
||||||
|
|
||||||
raise event.exception
|
raise event.exception
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue