From 657f7aa3d1effe9051b3e579542873f9784dd674 Mon Sep 17 00:00:00 2001 From: Aevann Date: Sun, 15 Oct 2023 18:13:22 +0300 Subject: [PATCH] handle suicide threads in WPD --- files/helpers/actions.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/files/helpers/actions.py b/files/helpers/actions.py index efffe01f4..76517181c 100644 --- a/files/helpers/actions.py +++ b/files/helpers/actions.py @@ -61,7 +61,9 @@ def execute_snappy(post, v): post_ping_group_count = len(list(group_mention_regex.finditer(post.body))) - if post_ping_group_count > 3: + if SITE_NAME == 'WPD' and ('killing myself' in post.title.lower() or (post.hole != 'suicide' and 'suicide' in post.title.lower())): + body = "https://i.watchpeopledie.tv/images/1697382435294321.webp" + elif post_ping_group_count > 3: body = "Unnecessary and uncalled for ping :marseydownvotemad: two more strikes and you're getting blocked + megadownvoted buddy, don't test your luck" vote = Vote(user_id=SNAPPY_ID, vote_type=-1,