Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

remind: use reply in case of error fix #1644 #1715

Merged
merged 1 commit into from
Nov 11, 2019
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions sopel/modules/remind.py
Original file line number Diff line number Diff line change
Expand Up @@ -198,10 +198,10 @@ def remind_monitoring(bot):
def remind_in(bot, trigger):
"""Gives you a reminder in the given amount of time."""
if not trigger.group(2):
bot.say("Missing arguments for reminder command.")
bot.reply("Missing arguments for reminder command.")
return module.NOLIMIT
if trigger.group(3) and not trigger.group(4):
bot.say("No message given for reminder.")
bot.reply("No message given for reminder.")
return module.NOLIMIT
duration = 0
message = filter(None, re.split(r'(\d+(?:\.\d+)? ?(?:(?i)' + PERIODS + ')) ?',
Expand Down Expand Up @@ -419,10 +419,10 @@ def remind_at(bot, trigger):
dd-mm-YY, or dd-mm. The separator can be ``.``, ``-``, or ``/``.
"""
if not trigger.group(2):
bot.say("No arguments given for reminder command.")
bot.reply("No arguments given for reminder command.")
return module.NOLIMIT
if trigger.group(3) and not trigger.group(4):
bot.say("No message given for reminder.")
bot.reply("No message given for reminder.")
return module.NOLIMIT

match = REGEX_AT.match(trigger.group(2))
Expand Down