Skip to content

Commit b08f2d6

Browse files
committed
Lint file
1 parent d41ac75 commit b08f2d6

1 file changed

Lines changed: 10 additions & 4 deletions

File tree

reply_cooldown/reply_cooldown.py

Lines changed: 10 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -20,15 +20,21 @@ async def setup(bot: ModmailBot) -> None:
2020
"""Monkey patch the built-in reply function to add a cooldown between uses."""
2121
_reply = Thread.reply
2222

23-
async def reply(self: commands.Cog, message: discord.Message, content: str = None, anonymous: bool = False, plain: bool = False) -> None:
23+
async def reply(
24+
self: commands.Cog,
25+
message: discord.Message,
26+
content: str = None,
27+
anonymous: bool = False,
28+
plain: bool = False,
29+
) -> None:
2430
"""The new reply function with a cooldown between uses."""
2531
# Bypass the cooldown if the message has attachments.
2632
if not message.attachments:
2733
for entry in MESSAGES_BUFFER:
2834
if (
29-
entry[0] == message.channel.id
30-
and entry[1] == message.content
31-
and entry[2] > (time.time() - COOLDOWN_TIME)
35+
entry[0] == message.channel.id
36+
and entry[1] == message.content
37+
and entry[2] > (time.time() - COOLDOWN_TIME)
3238
):
3339
await message.add_reaction("\u274c")
3440
return

0 commit comments

Comments
 (0)