Page MenuHomePhabricator

LotteryOdds incorrect calculation
Closed, ResolvedPublic

Description

File: /modules/jquery.articleFeedbackv5/jquery.articleFeedbackv5.verify.js
Line 203

If a article is a lottery-article is incorrect calculated:
Currently for odds=100 articles with e.g. curid=1000 still not included.

Proposed fix 1: return ( Number( article.id ) % 1000 ) > ( 999 - ( Number( odds ) * 10 ) );
Proposed fix 2: return ( Number( article.id ) % 1000 ) >= ( 1000 - ( Number( odds ) * 10 ) );


Version: master
Severity: normal

Details

Reference
bz42043