From 7678982f4ece55b411ef0c155a040845f4c0c8d2 Mon Sep 17 00:00:00 2001 From: Numerlor <25886452+Numerlor@users.noreply.github.com> Date: Sat, 14 Aug 2021 15:13:06 +0200 Subject: remove redundant typehints --- bot/exts/moderation/modpings.py | 1 - bot/exts/moderation/silence.py | 2 -- 2 files changed, 3 deletions(-) diff --git a/bot/exts/moderation/modpings.py b/bot/exts/moderation/modpings.py index 29a5c1c8e..80c9f0c38 100644 --- a/bot/exts/moderation/modpings.py +++ b/bot/exts/moderation/modpings.py @@ -87,7 +87,6 @@ class ModPings(Cog): The duration cannot be longer than 30 days. """ - duration: datetime.datetime delta = duration - datetime.datetime.utcnow() if delta > datetime.timedelta(days=30): await ctx.send(":x: Cannot remove the role for longer than 30 days.") diff --git a/bot/exts/moderation/silence.py b/bot/exts/moderation/silence.py index 8025f3df6..95e2792c3 100644 --- a/bot/exts/moderation/silence.py +++ b/bot/exts/moderation/silence.py @@ -202,8 +202,6 @@ class Silence(commands.Cog): duration: HushDurationConverter ) -> typing.Tuple[TextOrVoiceChannel, Optional[int]]: """Helper method to parse the arguments of the silence command.""" - duration: Optional[int] - if duration_or_channel: if isinstance(duration_or_channel, (TextChannel, VoiceChannel)): channel = duration_or_channel -- cgit v1.2.3