sneed
parent
ccca9a7684
commit
0f9bde0d7b
|
@ -150,7 +150,9 @@ def vote_post_comment(target_id, new, v, cls, vote_cls):
|
||||||
elif target.sub and target.sub not in ('space','istory','dino','slackernews'):
|
elif target.sub and target.sub not in ('space','istory','dino','slackernews'):
|
||||||
mul = 0.7
|
mul = 0.7
|
||||||
elif not target.sub and len(target.body) > 2000:
|
elif not target.sub and len(target.body) > 2000:
|
||||||
mul = 1 + len(target.body)/5000
|
x = target.body_html.count('" target="_blank" rel="nofollow noopener">')
|
||||||
|
x += target.body_html.count('<a href="/images/')
|
||||||
|
mul = 1 + x/20
|
||||||
|
|
||||||
mul = min(mul, 2)
|
mul = min(mul, 2)
|
||||||
target.realupvotes *= mul
|
target.realupvotes *= mul
|
||||||
|
|
Loading…
Reference in New Issue