Refine vocabulary selection logic in VocabLessonView to prevent duplicates

- Updated the condition for adding vocabulary options to ensure that normalized vocabulary entries are checked against the exclusion set, preventing duplicates and enhancing the learning experience.
This commit is contained in:
Torsten Schulz (local)
2026-01-20 15:09:37 +01:00
parent c907d2773d
commit eddbe5fa3f

View File

@@ -1070,7 +1070,7 @@ export default {
let index = 0; let index = 0;
while (options.size < 4 && index < genericOptions.length) { while (options.size < 4 && index < genericOptions.length) {
const option = genericOptions[index]; const option = genericOptions[index];
if (!excludeSet.has(option)) { if (!normalizedExcludeSet.has(this.normalizeVocab(option)) && !options.has(option)) {
options.add(option); options.add(option);
} }
index++; index++;