added another validation step to result saving

This commit is contained in:
Miodec 2021-03-01 22:54:37 +00:00
parent 00403028f0
commit c9423238bd

View file

@ -866,6 +866,14 @@ function validateResult(result) {
}
}
let wpmbad = false;
result.wpm.forEach((w) => {
if (w > 400) wpmbad = true;
});
if (wpmbad) return false;
if (result.consistency < 25) return false;
return true;
}