aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGravatar GDWR <[email protected]>2022-02-03 20:11:05 +0000
committerGravatar GDWR <[email protected]>2022-02-03 20:11:05 +0000
commite566a206b67af48c42159a5c0969fbddee76da1d (patch)
tree5b0f7627a4ba2f45fa429ec399bd7a28aa4fe387
parent👌 Remove the need to pass in channel via arguments (diff)
🚨 Linting fixes
-rw-r--r--bot/exts/help_channels/_cog.py5
-rw-r--r--bot/exts/help_channels/_message.py6
2 files changed, 8 insertions, 3 deletions
diff --git a/bot/exts/help_channels/_cog.py b/bot/exts/help_channels/_cog.py
index 78b01aa03..0fd631a6e 100644
--- a/bot/exts/help_channels/_cog.py
+++ b/bot/exts/help_channels/_cog.py
@@ -246,7 +246,10 @@ class HelpChannels(commands.Cog):
channel = await self.wait_for_dormant_channel() # Blocks until a new channel is available
else:
- last_notification = await _message.notify_running_low(self.channel_queue.qsize(), self.last_running_low_notification)
+ last_notification = await _message.notify_running_low(
+ self.channel_queue.qsize(),
+ self.last_running_low_notification
+ )
if last_notification:
self.last_running_low_notification = last_notification
diff --git a/bot/exts/help_channels/_message.py b/bot/exts/help_channels/_message.py
index 554aac7b4..d867dd93d 100644
--- a/bot/exts/help_channels/_message.py
+++ b/bot/exts/help_channels/_message.py
@@ -161,7 +161,8 @@ async def notify_none_remaining(last_notification: Arrow) -> t.Optional[Arrow]:
log.exception("Failed to send notification about lack of dormant channels!")
finally:
bot.instance.stats.incr("help.out_of_channel_alerts")
- return arrow.utcnow()
+
+ return arrow.utcnow()
async def notify_running_low(number_of_channels_left: int, last_notification: Arrow) -> t.Optional[Arrow]:
@@ -202,7 +203,8 @@ async def notify_running_low(number_of_channels_left: int, last_notification: Ar
log.exception("Failed to send notification about running low of dormant channels!")
finally:
bot.instance.stats.incr("help.running_low_alerts")
- return arrow.utcnow()
+
+ return arrow.utcnow()
async def pin(message: discord.Message) -> None: