mirror of
https://github.com/UiO-Gaming/mustafa.git
synced 2026-11-05 13:56:48 +01:00
show permission and owner errors for non slash commands
This commit is contained in:
1 parent
c6b2ac256d
commit
b094219a24
1 file changed
+3
-1
+3
-1
@@ -79,7 +79,7 @@ class Errors(commands.Cog):
|
||||
error = getattr(error, "original", error)
|
||||
|
||||
# Ignored errors
|
||||
ignored_errors = (commands.CommandNotFound, commands.DisabledCommand, commands.CheckFailure)
|
||||
ignored_errors = (commands.CommandNotFound, commands.DisabledCommand)
|
||||
if isinstance(error, ignored_errors):
|
||||
self.bot.logger.info("Ignored error", error)
|
||||
return
|
||||
@@ -101,6 +101,8 @@ class Errors(commands.Cog):
|
||||
)
|
||||
elif isinstance(error, commands.NoPrivateMessage):
|
||||
embed = embed_templates.error_warning("Denne kommandoen kan bare utføres it servere")
|
||||
elif isinstance(error, commands.CheckFailure):
|
||||
return
|
||||
else:
|
||||
embed = embed_templates.error_fatal("En ukjent feil oppstod!")
|
||||
f = discord.File("./src/assets/edb.png")
|
||||
|
||||
Reference in new issue
Block a user