aboutsummaryrefslogtreecommitdiffstats
path: root/bot/bot.py
diff options
context:
space:
mode:
authorGravatar Chris Goes <[email protected]>2019-03-25 22:41:34 -0600
committerGravatar GitHub <[email protected]>2019-03-25 22:41:34 -0600
commitc971c2822dce39abde76acffbded7bc03a58ba50 (patch)
treefc3e6484b77907bc0158c271af26261d013ae508 /bot/bot.py
parentMerge pull request #155 from python-discord/ci-cleanup (diff)
parentRemove unneeded fstring prefix. (diff)
Merge pull request #132 from python-discord/dpy-cog-changes
Add new Cog class inheritance & event listener decoration
Diffstat (limited to 'bot/bot.py')
-rw-r--r--bot/bot.py14
1 files changed, 2 insertions, 12 deletions
diff --git a/bot/bot.py b/bot/bot.py
index 3cc57c3f..d60390c3 100644
--- a/bot/bot.py
+++ b/bot/bot.py
@@ -5,7 +5,6 @@ from typing import List
from aiohttp import AsyncResolver, ClientSession, TCPConnector
from discord import Embed
-from discord.ext import commands
from discord.ext.commands import Bot
from bot import constants
@@ -19,10 +18,7 @@ class SeasonalBot(Bot):
def __init__(self, **kwargs):
super().__init__(**kwargs)
self.http_session = ClientSession(
- connector=TCPConnector(
- resolver=AsyncResolver(),
- family=socket.AF_INET,
- )
+ connector=TCPConnector(resolver=AsyncResolver(), family=socket.AF_INET)
)
def load_extensions(self, exts: List[str]):
@@ -49,6 +45,7 @@ class SeasonalBot(Bot):
"""
Send an embed message to the devlog channel
"""
+
devlog = self.get_channel(constants.Channels.devlog)
if not devlog:
@@ -62,10 +59,3 @@ class SeasonalBot(Bot):
embed.set_author(name=title, icon_url=icon)
await devlog.send(embed=embed)
-
- async def on_command_error(self, context, exception):
- # Don't punish the user for getting the arguments wrong
- if isinstance(exception, commands.UserInputError):
- context.command.reset_cooldown(context)
- else:
- await super().on_command_error(context, exception)