Merge pull request #660 from coralproject/math-is-hard

percents have to be multiplied by 100
This commit is contained in:
Riley Davis
2017-06-07 10:22:45 -06:00
committed by GitHub
@@ -80,7 +80,7 @@ export default class UserDetail extends React.Component {
profile = localProfile.id;
}
let rejectedPercent = rejectedComments / totalComments;
let rejectedPercent = (rejectedComments / totalComments) * 100;
if (rejectedPercent === Infinity || isNaN(rejectedPercent)) {
// if totalComments is 0, you're dividing by zero, which is naughty