From 4e6942194f9578f5b999fb98a971f18323fc9da7 Mon Sep 17 00:00:00 2001 From: Xua <17090652+XuaTheGrate@users.noreply.github.com> Date: Fri, 8 May 2020 21:48:44 +1200 Subject: [PATCH] [commands] Document that cog_command_error must be async --- discord/ext/commands/cog.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/discord/ext/commands/cog.py b/discord/ext/commands/cog.py index fc4d43e21..5c81e4a5a 100644 --- a/discord/ext/commands/cog.py +++ b/discord/ext/commands/cog.py @@ -312,14 +312,14 @@ class Cog(metaclass=CogMeta): return True @_cog_special_method - def cog_command_error(self, ctx, error): + async def cog_command_error(self, ctx, error): """A special method that is called whenever an error is dispatched inside this cog. This is similar to :func:`.on_command_error` except only applying to the commands inside this cog. - This function **can** be a coroutine. + This **must** be a coroutine. Parameters -----------