mirror of
https://github.com/monkeytypegame/monkeytype.git
synced 2024-09-22 08:16:20 +08:00
fixed results being added to the wrong bucket of the account histogram chart
This commit is contained in:
parent
5ff41ded22
commit
959812af31
|
@ -523,6 +523,9 @@ function fillContent(): void {
|
|||
}
|
||||
|
||||
const bucket = Math.floor(result.wpm / 10) * 10;
|
||||
const bucket2 = Math.floor(Math.round(result.wpm) / 10) * 10;
|
||||
|
||||
if (bucket !== bucket2) console.log(result.wpm, bucket, bucket2);
|
||||
|
||||
if (Object.keys(histogramChartData).includes(String(bucket))) {
|
||||
histogramChartData[bucket]++;
|
||||
|
|
Loading…
Reference in a new issue