master
Aevann1 2021-09-05 13:38:57 +02:00
parent 3962434898
commit 86d8840b8e
1 changed files with 4 additions and 4 deletions

View File

@ -181,11 +181,11 @@ def post_id(pid, anything=None, v=None):
post.preloaded_comments = [x for x in comments if not (x.author and x.author.shadowbanned) or (v and v.id == x.author_id)]
read = session["read_comments"]
read_comments = [x.id for x in post.preloaded_comments]
if session.get("read_comments"): session["read_comments"] += read_comments
else: session["read_comments"] = read_comments
read = session["read_comments"]
read_comments = [x.id for x in post.preloaded_comments]
if session.get("read_comments"): session["read_comments"] += read_comments
else: session["read_comments"] = read_comments
post.views += 1
g.db.add(post)