give a permenant progstack effect to ('slackernews','space','istory','dinos')

remotes/1693045480750635534/spooky-22
Aevann1 2022-08-23 17:28:00 +02:00
parent f6e6d07504
commit 83e8d7b015
1 changed files with 2 additions and 1 deletions

View File

@ -125,7 +125,8 @@ def vote_post(post_id, new, v):
post.upvotes = g.db.query(Vote).filter_by(submission_id=post.id, vote_type=1).count()
post.downvotes = g.db.query(Vote).filter_by(submission_id=post.id, vote_type=-1).count()
post.realupvotes = g.db.query(Vote).filter_by(submission_id=post.id, real=True).count()
if post.author.progressivestack: post.realupvotes *= 2
if post.author.progressivestack or post.sub in ('slackernews','space','istory','dinos'):
post.realupvotes *= 2
g.db.add(post)
return "", 204