mirror of
https://github.com/monkeytypegame/monkeytype.git
synced 2025-02-11 00:03:44 +08:00
changed how funbox was called in command-lists
This commit is contained in:
parent
dde90f829c
commit
2df9fc379c
2 changed files with 7 additions and 5 deletions
|
@ -126,8 +126,9 @@ let commandsFunbox = {
|
|||
id: "changeFunboxNone",
|
||||
display: "none",
|
||||
exec: () => {
|
||||
Funbox.setFunbox("none", null);
|
||||
TestLogic.restart();
|
||||
if (Funbox.setFunbox("none", null)) {
|
||||
TestLogic.restart();
|
||||
}
|
||||
},
|
||||
},
|
||||
],
|
||||
|
@ -139,8 +140,9 @@ Misc.getFunboxList().then((funboxes) => {
|
|||
id: "changeFunbox" + funbox.name,
|
||||
display: funbox.name.replace(/_/g, " "),
|
||||
exec: () => {
|
||||
Funbox.setFunbox(funbox.name, funbox.type);
|
||||
TestLogic.restart();
|
||||
if (Funbox.setFunbox(funbox.name, funbox.type)) {
|
||||
TestLogic.restart();
|
||||
}
|
||||
},
|
||||
});
|
||||
});
|
||||
|
|
|
@ -624,9 +624,9 @@ export function restart(withSameWordset = false, nosave = false, event) {
|
|||
// incompleteTestSeconds += ;
|
||||
TestStats.incrementIncompleteSeconds(testSeconds - afkseconds);
|
||||
TestStats.incrementRestartCount();
|
||||
|
||||
// restartCount++;
|
||||
}
|
||||
|
||||
if (Config.mode == "zen") {
|
||||
$("#words").empty();
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue