summaryrefslogtreecommitdiffstats
path: root/modules/tell.py
diff options
context:
space:
mode:
authorSean B. Palmer <http://inamidst.com/sbp/>2008-03-31 16:17:32 +0100
committerSean B. Palmer <http://inamidst.com/sbp/>2008-03-31 16:17:32 +0100
commit286d4a8497621d2f3c0f1f8d66db60b11c87fad5 (patch)
tree23493e843bcb1a1d6b25346a3dfd6290df46d5ba /modules/tell.py
parentfb2cd452e963b8bc048161036903cd82d3b113f0 (diff)
downloadbot-286d4a8497621d2f3c0f1f8d66db60b11c87fad5.tar.gz
bot-286d4a8497621d2f3c0f1f8d66db60b11c87fad5.tar.bz2
bot-286d4a8497621d2f3c0f1f8d66db60b11c87fad5.zip
New "limit" config variable, and some module fixes.
Diffstat (limited to 'modules/tell.py')
-rwxr-xr-xmodules/tell.py8
1 files changed, 4 insertions, 4 deletions
diff --git a/modules/tell.py b/modules/tell.py
index dc8ea46..ef9f171 100755
--- a/modules/tell.py
+++ b/modules/tell.py
@@ -65,7 +65,7 @@ def f_remind(phenny, input):
msg = msg.encode('utf-8')
tellee_original = tellee.rstrip(',:;')
- tellee = tellee.lower()
+ tellee = tellee_original.lower()
if not os.path.exists(phenny.tell_filename):
return
@@ -90,7 +90,7 @@ def f_remind(phenny, input):
rand = random.random()
if rand > 0.9999: response = "yeah, yeah"
- elif rand > 0.999: response = "%s: yeah, sure, whatever" % teller
+ elif rand > 0.999: response = "yeah, sure, whatever"
phenny.reply(response)
elif teller.lower() == tellee:
@@ -126,10 +126,10 @@ def message(phenny, input):
reminders = []
remkeys = list(reversed(sorted(phenny.reminders.keys())))
for remkey in remkeys:
- if not remkey.endswith('*'):
+ if not remkey.endswith('*') or remkey.endswith(':'):
if tellee.lower() == remkey:
reminders.extend(getReminders(phenny, channel, remkey, tellee))
- elif tellee.lower().startswith(remkey.rstrip('*')):
+ elif tellee.lower().startswith(remkey.rstrip('*:')):
reminders.extend(getReminders(phenny, channel, remkey, tellee))
for line in reminders[:maximum]: