From 4c38cb24ac1308c12a79a8c435e4bb3ada0916af Mon Sep 17 00:00:00 2001 From: Aevann Date: Wed, 1 Mar 2023 00:39:39 +0200 Subject: [PATCH] fix 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 b6779e890..079edc14a 100644 --- a/files/classes/comment.py +++ b/files/classes/comment.py @@ -297,7 +297,7 @@ class Comment(Base): if f'{s}{o.body}{s}' in body: body = body.replace(f'{s}{o.body}{s}', option_body) - elif o.created_utc < 1677622477: + elif not o.created_utc or o.created_utc < 1677622477: body += option_body if not self.ghost and self.author.show_sig(v): diff --git a/files/classes/submission.py b/files/classes/submission.py index cd0a84edc..54af35ec9 100644 --- a/files/classes/submission.py +++ b/files/classes/submission.py @@ -326,7 +326,7 @@ class Submission(Base): if f'{s}{o.body}{s}' in body: body = body.replace(f'{s}{o.body}{s}', option_body) - elif o.created_utc < 1677622477: + elif not o.created_utc or o.created_utc < 1677622477: body += option_body if not listing and not self.ghost and self.author.show_sig(v):