From f833729224e690214afa5e16f05759adf2a601fd Mon Sep 17 00:00:00 2001 From: Aevann1 Date: Tue, 5 Apr 2022 15:31:40 +0200 Subject: [PATCH] fds --- files/routes/comments.py | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) diff --git a/files/routes/comments.py b/files/routes/comments.py index 9558700c8..ea5775772 100644 --- a/files/routes/comments.py +++ b/files/routes/comments.py @@ -326,9 +326,6 @@ def api_comment(v): body_html = sanitize(body, comment=True) - if v.marseyawarded and parent_post.id not in ADMIGGERS and marseyaward_body_regex.search(body_html): - return {"error":"You can only type marseys!"}, 403 - bans = filter_comment_html(body_html) if bans: @@ -660,11 +657,16 @@ def api_comment(v): check_for_blackjack_commands(body, v, c) - check_for_treasure(body, c) + if not c.slots_result and not c.blackjack_result: + + if v.marseyawarded and parent_post.id not in ADMIGGERS and marseyaward_body_regex.search(body_html): + return {"error":"You can only type marseys!"}, 403 - if not c.slots_result and not c.blackjack_result and not c.wordle_result and not rts: - parent_post.comment_count += 1 - g.db.add(parent_post) + if not c.wordle_result and not rts: + parent_post.comment_count += 1 + g.db.add(parent_post) + + check_for_treasure(body, c) if "!wordle" in body: answer = random.choice(WORDLE_LIST)