From 294847d3890b91ebe3c213b81451fddaaabe8465 Mon Sep 17 00:00:00 2001 From: Miodec Date: Mon, 25 Nov 2024 17:46:50 +0100 Subject: chore: add debug log to addWord function !nuf --- frontend/src/ts/test/test-logic.ts | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/frontend/src/ts/test/test-logic.ts b/frontend/src/ts/test/test-logic.ts index 147ab8c4a..a2aa2882c 100644 --- a/frontend/src/ts/test/test-logic.ts +++ b/frontend/src/ts/test/test-logic.ts @@ -545,10 +545,13 @@ export async function addWord(): Promise { ?.properties?.find((fp) => fp.startsWith("toPush:")); const toPushCount = funboxToPush?.split(":")[1]; if (toPushCount !== undefined) bound = +toPushCount - 1; - if ( - TestWords.words.length - TestInput.input.history.length > bound || - areAllTestWordsGenerated() - ) { + + if (TestWords.words.length - TestInput.input.history.length > bound) { + console.debug("Not adding word, enough words already"); + return; + } + if (areAllTestWordsGenerated()) { + console.debug("Not adding word, all words generated"); return; } -- cgit v1.2.3