From 234ed590496bbb369bddfda40d82744b7617ccb5 Mon Sep 17 00:00:00 2001 From: b3yond Date: Mon, 24 Sep 2018 22:40:29 +0200 Subject: [PATCH] don't require correctly cased mail addresses --- active_bots/mailbot.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/active_bots/mailbot.py b/active_bots/mailbot.py index 4ceca50..8125137 100644 --- a/active_bots/mailbot.py +++ b/active_bots/mailbot.py @@ -22,7 +22,7 @@ class Mailbot(Bot): mails = mailbox.mbox("/var/mail/" + config['mail']['mbox_user']) for msg in mails: if get_date_from_header(msg['Date']) > user.get_seen_mail(): - if user.get_city() in msg['To']: + if user.get_city().lower() in msg['To'].lower(): reports.append(make_report(msg, user)) return reports