From b3ddac8f941410a64eb625922ec4290fb5a29d88 Mon Sep 17 00:00:00 2001 From: retoor Date: Mon, 6 Jan 2025 18:14:04 +0000 Subject: [PATCH] Fixed ragnar mention. --- src/ragnar/bot.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/ragnar/bot.py b/src/ragnar/bot.py index f56dab5..eec12fd 100644 --- a/src/ragnar/bot.py +++ b/src/ragnar/bot.py @@ -116,6 +116,9 @@ class Bot: rant = self.api.get_rant(rant_id) for comment in rant.get("comments", []): print("Checking if sus comment: ", comment["body"]) + if '@ragnar' in comment.get('body',''): + print("Ragnar is mentioned, so flagging as sus comment.") + return True if comment["user_score"] >= 5: print("User has reputation >= 5 so not sus.") continue