fix pinning logic for holes

remotes/1693045480750635534/spooky-22
Aevann1 2022-07-13 23:20:56 +02:00
parent 9e05f0a3b5
commit 6689172013
1 changed files with 2 additions and 1 deletions

View File

@ -104,7 +104,8 @@ def frontlist(v=None, sort="hot", page=1, t="all", ids_only=True, ccmode="false"
posts = posts.filter_by(is_banned=False, private=False, deleted_utc = 0)
if pins and ccmode == "false" and not gt and not lt:
posts = posts.filter_by(stickied=None, hole_pinned=None)
if sub: posts = posts.filter_by(hole_pinned=None)
else: posts = posts.filter_by(stickied=None)
if v:
posts = posts.filter(Submission.author_id.notin_(v.userblocks))