From 8b1cf509653a0cb7cc67a38e7075f9133c26937b Mon Sep 17 00:00:00 2001 From: Aevann1 Date: Thu, 6 Oct 2022 23:17:35 +0200 Subject: [PATCH] fix misplaced ")" resulting in 500 error --- files/classes/comment.py | 2 +- files/classes/submission.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/files/classes/comment.py b/files/classes/comment.py index 1c19786bf..5c4675b1a 100644 --- a/files/classes/comment.py +++ b/files/classes/comment.py @@ -330,7 +330,7 @@ class Comment(Base): def realbody(self, v): if self.post and self.post.club and not (v and (v.paid_dues or v.id in [self.author_id, self.post.author_id] or (self.parent_comment and v.id == self.parent_comment.author_id))): return f"

{CC} ONLY

" - if self.deleted_utc != 0 and not (v and (v.admin_level >= 2) or v.id == self.author.id): return "[Deleted by user]" + if self.deleted_utc != 0 and not (v and (v.admin_level >= 2 or v.id == self.author.id)): return "[Deleted by user]" if self.is_banned and not (v and v.admin_level >= 2): return "[Removed by admins]"; body = self.body_html or "" diff --git a/files/classes/submission.py b/files/classes/submission.py index 046aa1681..5386bbecf 100644 --- a/files/classes/submission.py +++ b/files/classes/submission.py @@ -334,7 +334,7 @@ class Submission(Base): @lazy def realbody(self, v, listing=False): if self.club and not (v and (v.paid_dues or v.id == self.author_id)): return f"

{CC} ONLY

" - if self.deleted_utc != 0 and not (v and (v.admin_level >= 2) or v.id == self.author.id): return "[Deleted by user]" + if self.deleted_utc != 0 and not (v and (v.admin_level >= 2 or v.id == self.author.id)): return "[Deleted by user]" if self.is_banned and not (v and v.admin_level >= 2): return "[Removed by admins]" body = self.body_html or ""