aboutsummaryrefslogtreecommitdiffstats
path: root/bot/cogs/error_handler.py
diff options
context:
space:
mode:
authorGravatar Leon Sandøy <[email protected]>2018-11-20 13:05:50 +0100
committerGravatar Leon Sandøy <[email protected]>2018-11-20 13:05:50 +0100
commit3c48779978082dc6907ef5849b655759c19d008d (patch)
tree8a9c1e4a1b4b875ef9901fdee7ecad390def080a /bot/cogs/error_handler.py
parentMerge branch 'master' of https://github.com/DerpDays/hacktoberbot into DerpDa... (diff)
solving some flake8 issues
Diffstat (limited to 'bot/cogs/error_handler.py')
-rw-r--r--bot/cogs/error_handler.py9
1 files changed, 5 insertions, 4 deletions
diff --git a/bot/cogs/error_handler.py b/bot/cogs/error_handler.py
index 9f0da2e0..79780251 100644
--- a/bot/cogs/error_handler.py
+++ b/bot/cogs/error_handler.py
@@ -1,7 +1,8 @@
+import logging
+import math
import sys
import traceback
-import math
-import logging
+
from discord.ext import commands
@@ -41,7 +42,7 @@ class CommandErrorHandler:
)
return await ctx.send(
"This command is on cooldown," +
- " please retry in {}s.".format(math.ceil(error.retry_after))
+ f" please retry in {math.ceil(error.retry_after)}s."
)
if isinstance(error, commands.DisabledCommand):
logging.debug(
@@ -85,7 +86,7 @@ class CommandErrorHandler:
":no_entry: You are not authorized to use this command."
)
print(
- "Ignoring exception in command {}:".format(ctx.command),
+ f"Ignoring exception in command {ctx.command}:",
file=sys.stderr
)
logging.warning(