This commit is contained in:
Aevann1 2021-11-26 02:32:38 +02:00
parent d4655979a8
commit 2ef949e646
3 changed files with 6 additions and 2 deletions

View file

@ -127,7 +127,7 @@ def post_id(pid, anything=None, v=None):
if post.club and not (v and v.paid_dues) or post.private and not (v and (v.id == post.author_id or v.admin_level > 1)): abort(403)
if request.host == 'rdrama.net' and pid == 22479: sort = 'new'
if request.host == 'rdrama.net' and [BUG_THREAD, EMOJI_THREAD]: sort = 'new'
if v:
votes = g.db.query(CommentVote).filter_by(user_id=v.id).subquery()
@ -200,7 +200,7 @@ def post_id(pid, anything=None, v=None):
post.replies = comments.filter(Comment.is_pinned != None).all() + comments.filter(Comment.level == 1, Comment.is_pinned == None).all()
if request.host == 'rdrama.net' and pid == 22479: post.replies = post.replies[:20]
if request.host == 'rdrama.net' and pid in [BUG_THREAD, EMOJI_THREAD]: post.replies = post.replies[:10]
post.views += 1
g.db.add(post)