From af52afb4089c6dafddbcac6587f309a077ea0354 Mon Sep 17 00:00:00 2001 From: Aevann Date: Wed, 19 Jul 2023 13:00:59 +0300 Subject: [PATCH] use abort in vote --- files/routes/votes.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/files/routes/votes.py b/files/routes/votes.py index 1f6e717a3..ca2bbd5cf 100644 --- a/files/routes/votes.py +++ b/files/routes/votes.py @@ -154,7 +154,7 @@ def vote_post_comment(target_id, new, v, cls, vote_cls): return 0 try: g.db.flush() - except: g.db.rollback() + except: abort(500) return votes.count()