made sure consistency cannot be nan

This commit is contained in:
Jack 2020-07-30 18:00:22 +01:00
parent 01dfd54d63
commit df029cc215

View file

@ -1375,6 +1375,10 @@ function showResult(difficultyFailed = false) {
let consistency = roundTo2(kogasa(stddev / avg));
if (isNaN(consistency)) {
consistency = 0;
}
$("#result .stats .consistency .bottom").text(Math.round(consistency) + "%");
$("#result .stats .consistency .bottom").attr(
"aria-label",