mirror of
https://github.com/Cog-Creators/Red-DiscordBot.git
synced 2025-11-21 10:17:59 -05:00
[V3] Custom context class (#988)
* Create custom context class * Documentation * Remove old help method, replace with new * Update from rebase
This commit is contained in:
@@ -74,9 +74,9 @@ def init_events(bot, cli_flags):
|
||||
@bot.event
|
||||
async def on_command_error(ctx, error):
|
||||
if isinstance(error, commands.MissingRequiredArgument):
|
||||
await bot.send_cmd_help(ctx)
|
||||
await ctx.send_help()
|
||||
elif isinstance(error, commands.BadArgument):
|
||||
await bot.send_cmd_help(ctx)
|
||||
await ctx.send_help()
|
||||
elif isinstance(error, commands.DisabledCommand):
|
||||
await ctx.send("That command is disabled.")
|
||||
elif isinstance(error, commands.CommandInvokeError):
|
||||
|
||||
Reference in New Issue
Block a user