aboutsummaryrefslogtreecommitdiffstats
path: root/bot/seasons/evergreen/error_handler.py
diff options
context:
space:
mode:
authorGravatar sco1 <[email protected]>2019-03-30 10:40:38 -0400
committerGravatar sco1 <[email protected]>2019-03-30 10:42:02 -0400
commit095dc1791f147682023edafc59abdc4019074eeb (patch)
tree160d7ee160042befbfba778e54507a5eee3bd686 /bot/seasons/evergreen/error_handler.py
parentMerge branch 'master' into hotfix (diff)
parentMerge pull request #146 from python-discord/flake8-docstring (diff)
Merge branch 'master' into hotfix
Diffstat (limited to 'bot/seasons/evergreen/error_handler.py')
-rw-r--r--bot/seasons/evergreen/error_handler.py8
1 files changed, 5 insertions, 3 deletions
diff --git a/bot/seasons/evergreen/error_handler.py b/bot/seasons/evergreen/error_handler.py
index 7774f06e..b0d05c41 100644
--- a/bot/seasons/evergreen/error_handler.py
+++ b/bot/seasons/evergreen/error_handler.py
@@ -8,8 +8,8 @@ from discord.ext import commands
log = logging.getLogger(__name__)
-class CommandErrorHandler(commands.Cog):
- """A error handler for the PythonDiscord server!"""
+class CommandErrorHandler:
+ """A error handler for the PythonDiscord server."""
def __init__(self, bot):
self.bot = bot
@@ -26,7 +26,7 @@ class CommandErrorHandler(commands.Cog):
@commands.Cog.listener()
async def on_command_error(self, ctx, error):
- """Activates when a command opens an error"""
+ """Activates when a command opens an error."""
if hasattr(ctx.command, 'on_error'):
return logging.debug(
@@ -100,5 +100,7 @@ class CommandErrorHandler(commands.Cog):
def setup(bot):
+ """Error handler Cog load."""
+
bot.add_cog(CommandErrorHandler(bot))
log.info("CommandErrorHandler cog loaded")