forked from rDrama/rDrama
1
0
Fork 0

fix 500 error

master
Aevann 2023-11-20 18:25:18 +02:00
parent eaaab06af0
commit 77bb4af171
1 changed files with 1 additions and 1 deletions

View File

@ -1145,7 +1145,7 @@ def chud(fullname, v):
try: comment = int(reason.split("/comment/")[1].split(None, 1)[0])
except: abort(400)
comment = get_comment(comment)
if comment.post.hole == 'chudrama':
if comment.parent_post and comment.post.hole == 'chudrama':
abort(403, "You can't chud people in /h/chudrama")
comment.chuddedfor = f'{duration} by @{v.username}'
g.db.add(comment)