From ab3ec6a1588abaeaa8e3257fabfe11ed25467c5a Mon Sep 17 00:00:00 2001 From: Aevann1 Date: Sun, 2 Jan 2022 19:13:51 +0200 Subject: [PATCH] fdsfds --- files/routes/awards.py | 16 ---------------- 1 file changed, 16 deletions(-) diff --git a/files/routes/awards.py b/files/routes/awards.py index 2e7b7db4c4..9f86986da6 100644 --- a/files/routes/awards.py +++ b/files/routes/awards.py @@ -210,14 +210,6 @@ def award_post(pid, v): if not post: return {"error": "That post doesn't exist."}, 404 - existing_award = g.db.query(AwardRelationship).filter( - and_( - AwardRelationship.submission_id == post.id, - AwardRelationship.user_id == v.id, - AwardRelationship.kind == kind - ) - ).first() - post_award.submission_id = post.id g.db.add(post_award) @@ -384,14 +376,6 @@ def award_comment(cid, v): if not c: return {"error": "That comment doesn't exist."}, 404 - existing_award = g.db.query(AwardRelationship).filter( - and_( - AwardRelationship.comment_id == c.id, - AwardRelationship.user_id == v.id, - AwardRelationship.kind == kind - ) - ).first() - comment_award.comment_id = c.id g.db.add(comment_award)