From 0c414faa2728218ec614de2f8f800ee59e9ed1fb Mon Sep 17 00:00:00 2001 From: Aevann Date: Sun, 19 May 2024 07:02:28 +0300 Subject: [PATCH] flush --- files/helpers/sanitize.py | 1 + 1 file changed, 1 insertion(+) diff --git a/files/helpers/sanitize.py b/files/helpers/sanitize.py index 868fc8156..8822c4b2b 100644 --- a/files/helpers/sanitize.py +++ b/files/helpers/sanitize.py @@ -97,6 +97,7 @@ def execute_blackjack(v, target, body, kind): extra_info = f"reports on {target.permalink}" elif kind in {'comment', 'message'}: for id in notified_ids: + g.db.flush() existing = g.db.query(Notification).filter_by(comment_id=target.id, user_id=id).one_or_none() if existing: continue n = Notification(comment_id=target.id, user_id=id)