aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGravatar Mark <[email protected]>2020-10-02 12:03:36 -0700
committerGravatar GitHub <[email protected]>2020-10-02 12:03:36 -0700
commit415ac1a4f99195c77f32495c1146023b7591f3b7 (patch)
tree1bd84d9386a283032636e0a15be7a5c65f023673
parentMerge pull request #860 from ks129/discord-py-upgrade-migrate (diff)
parentReminder: no feedback message when no mention (diff)
Merge pull request #1208 from python-discord/reminder-no-mention
Reminder: no feedback message when no mention is used
-rw-r--r--bot/exts/utils/reminders.py9
1 files changed, 5 insertions, 4 deletions
diff --git a/bot/exts/utils/reminders.py b/bot/exts/utils/reminders.py
index efba7ad6e..b8c15853f 100644
--- a/bot/exts/utils/reminders.py
+++ b/bot/exts/utils/reminders.py
@@ -286,10 +286,11 @@ class Reminders(Cog):
now = datetime.utcnow() - timedelta(seconds=1)
humanized_delta = humanize_delta(relativedelta(expiration, now))
- mention_string = (
- f"Your reminder will arrive in {humanized_delta} "
- f"and will mention {len(mentions)} other(s)!"
- )
+ mention_string = f"Your reminder will arrive in {humanized_delta}"
+
+ if mentions:
+ mention_string += f" and will mention {len(mentions)} other(s)"
+ mention_string += "!"
# Confirm to the user that it worked.
await self._send_confirmation(