From b7e91895b05b353640ac7f55555a4eb586de11a7 Mon Sep 17 00:00:00 2001 From: Leonabcd123 <156839416+Leonabcd123@users.noreply.github.com> Date: Fri, 26 Jun 2026 13:49:04 +0300 Subject: [PATCH 1/2] fix(wikipedia): skip empty pages --- frontend/src/ts/test/wikipedia.ts | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/frontend/src/ts/test/wikipedia.ts b/frontend/src/ts/test/wikipedia.ts index af890e5a1c2d..7e12471919d1 100644 --- a/frontend/src/ts/test/wikipedia.ts +++ b/frontend/src/ts/test/wikipedia.ts @@ -100,6 +100,12 @@ export async function getSection( // Removing whitespace before and after text sectionText = sectionText.trim(); + // If this section is empty, fetch another one + if (!sectionText) { + res(getSection(language)); + return; + } + const words = sectionText.split(" "); const section = new JSONData.Section( From a806fd6d92b7f6c92dd84832ebb2dc3917e74442 Mon Sep 17 00:00:00 2001 From: Leonabcd123 <156839416+Leonabcd123@users.noreply.github.com> Date: Fri, 26 Jun 2026 20:51:41 +0300 Subject: [PATCH 2/2] Explicit --- frontend/src/ts/test/wikipedia.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/frontend/src/ts/test/wikipedia.ts b/frontend/src/ts/test/wikipedia.ts index 7e12471919d1..4519d06641eb 100644 --- a/frontend/src/ts/test/wikipedia.ts +++ b/frontend/src/ts/test/wikipedia.ts @@ -101,7 +101,7 @@ export async function getSection( sectionText = sectionText.trim(); // If this section is empty, fetch another one - if (!sectionText) { + if (sectionText === "") { res(getSection(language)); return; }