forked from rDrama/rDrama
fdfd
parent
b7522a5960
commit
c94ffa3adf
|
@ -101,7 +101,7 @@ def api_vote_post(post_id, new, v):
|
||||||
post.author.coins += 1
|
post.author.coins += 1
|
||||||
post.author.truecoins += 1
|
post.author.truecoins += 1
|
||||||
g.db.add(post.author)
|
g.db.add(post.author)
|
||||||
real = bool(v.profileurl) or bool(v.customtitle) or v.namecolor != defaultcolor
|
real = bool(v.profileurl) or bool(v.customtitle) or v.namecolor != defaultcolor and not v.agendaposter and not v.shadowbanned
|
||||||
vote = Vote(user_id=v.id,
|
vote = Vote(user_id=v.id,
|
||||||
vote_type=new,
|
vote_type=new,
|
||||||
submission_id=post_id,
|
submission_id=post_id,
|
||||||
|
@ -169,7 +169,7 @@ def api_vote_comment(comment_id, new, v):
|
||||||
comment.author.coins += 1
|
comment.author.coins += 1
|
||||||
comment.author.truecoins += 1
|
comment.author.truecoins += 1
|
||||||
g.db.add(comment.author)
|
g.db.add(comment.author)
|
||||||
real = bool(v.profileurl) or bool(v.customtitle) or v.namecolor != defaultcolor
|
real = (bool(v.profileurl) or bool(v.customtitle) or v.namecolor != defaultcolor) and not v.agendaposter and not v.shadowbanned
|
||||||
vote = CommentVote(user_id=v.id,
|
vote = CommentVote(user_id=v.id,
|
||||||
vote_type=new,
|
vote_type=new,
|
||||||
comment_id=comment_id,
|
comment_id=comment_id,
|
||||||
|
|
Loading…
Reference in New Issue