🥅 Added an error message
This commit is contained in:
@ -78,8 +78,11 @@ async def on_command(ctx):
|
|||||||
async def on_command_error(ctx, error):
|
async def on_command_error(ctx, error):
|
||||||
if isinstance(error, commands.CommandNotFound):
|
if isinstance(error, commands.CommandNotFound):
|
||||||
await ctx.send("That's not a command (error code 001)")
|
await ctx.send("That's not a command (error code 001)")
|
||||||
|
elif isinstance(error,commands.errors.MissingRequiredArgument):
|
||||||
|
logThis(f"{error}",str(ctx.message.channel.id))
|
||||||
|
await ctx.send("Missing command parameters (error code 002). Try using `!help [command]` to find out how to use the command.")
|
||||||
else:
|
else:
|
||||||
logThis(f"Something went wrong, {error}",str(ctx.message.channel.id))
|
logThis(f"Something went wrong, {error}, ({type(error)})",str(ctx.message.channel.id))
|
||||||
await ctx.send("Something went wrong (error code 000)")
|
await ctx.send("Something went wrong (error code 000)")
|
||||||
|
|
||||||
#Loads cogs
|
#Loads cogs
|
||||||
|
Reference in New Issue
Block a user