mirror of
https://github.com/monkeytypegame/monkeytype.git
synced 2026-01-11 01:44:50 +08:00
fix(word generation): plus n funboxes causing custom tests to go over the limit
This commit is contained in:
parent
99cc7042ea
commit
42aa055eb4
1 changed files with 10 additions and 0 deletions
|
|
@ -403,6 +403,8 @@ export function getWordsLimit(): number {
|
|||
if (Config.mode === "words" && Config.words === 0) {
|
||||
limit = 100;
|
||||
}
|
||||
|
||||
//custom
|
||||
if (Config.mode === "custom") {
|
||||
if (
|
||||
CustomText.getLimitValue() === 0 ||
|
||||
|
|
@ -426,6 +428,14 @@ export function getWordsLimit(): number {
|
|||
limit = Config.words;
|
||||
}
|
||||
|
||||
if (
|
||||
Config.mode === "custom" &&
|
||||
CustomText.getLimitMode() === "word" &&
|
||||
CustomText.getLimitValue() < limit
|
||||
) {
|
||||
limit = CustomText.getLimitValue();
|
||||
}
|
||||
|
||||
return limit;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue