From: Thorsten Date: Tue, 12 Dec 2023 20:05:46 +0000 (+0100) Subject: fix upper/lower case X-Git-Url: https://git.aero2k.de/?a=commitdiff_plain;h=d49129ed77cc0f8061b45f30f5e75c1be1e05af8;p=urlbot-v3.git fix upper/lower case --- diff --git a/distbot/plugins/didyouknow.py b/distbot/plugins/didyouknow.py index f4ebf6b..a9fdbfa 100644 --- a/distbot/plugins/didyouknow.py +++ b/distbot/plugins/didyouknow.py @@ -37,7 +37,7 @@ class DidYouKnow(Worker): def parse_body(self, msg): sender = get_nick_from_message(msg) words = get_words(msg) - if "wusstet" in words: + if "wusstet" in map(lambda w: w.lower(), words): fact = self.get_random_fact() self.insert_fact(msg) answer = random.choice(self.answers)