mirror of
https://github.com/monkeytypegame/monkeytype.git
synced 2025-11-07 03:19:13 +08:00
fixed burst heatmap not working in zen. closes #2327
This commit is contained in:
parent
dc1536fbd0
commit
bc160812a1
2 changed files with 4 additions and 1 deletions
|
|
@ -237,6 +237,9 @@ export function calculateBurst() {
|
|||
let wordLength;
|
||||
if (Config.mode === "zen") {
|
||||
wordLength = TestLogic.input.current.length;
|
||||
if (wordLength == 0) {
|
||||
wordLength = TestLogic.input.getHistoryLast().length;
|
||||
}
|
||||
} else {
|
||||
wordLength = TestLogic.words.getCurrent().length;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -907,7 +907,7 @@ export function applyBurstHeatmap() {
|
|||
|
||||
if (
|
||||
TestLogic.input.getHistory(TestLogic.input.getHistory().length - 1)
|
||||
.length !== TestLogic.words.getCurrent().length
|
||||
.length !== TestLogic.words.getCurrent()?.length
|
||||
) {
|
||||
burstlist = burstlist.splice(0, burstlist.length - 1);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue