Potential fix for pull request finding

Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
This commit is contained in:
Erik van der Boom 2026-07-22 00:36:12 +02:00 committed by GitHub
parent 5310e631ae
commit 2401d382ca
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -1758,7 +1758,8 @@ function getLanguageFolderNames(root: string, language: string): string[] {
const upper = language.toUpperCase();
const names = new Set<string>([upper]);
const settings = readSettings(root);
for (const entry of settings?.languages ?? []) {
const languages = Array.isArray(settings?.languages) ? settings.languages : [];
for (const entry of languages) {
if (entry.code.toUpperCase() !== upper) { continue; }
if (typeof entry.folderName === 'string' && entry.folderName.trim()) {
names.add(entry.folderName.trim());