mirror of
https://gitcode.com/gh_mirrors/hy/Hydro.git
synced 2026-10-17 17:36:08 +08:00
core: fix lang list check
This commit is contained in:
2 files changed
+3
-3
No files matched your search
@@ -32,7 +32,7 @@ export function getAvailableLangs(langsList?: string[]) {
|
||||
const Langs = {};
|
||||
for (const key in window.LANGS) {
|
||||
if (prefixes.has(key)) continue;
|
||||
if (langsList && langsList.length && langsList.join('') && !langsList.includes(key)) continue;
|
||||
if ((langsList instanceof Array) && !langsList.includes(key)) continue;
|
||||
if (window.LANGS[key].hidden && !langsList?.includes(key)) continue;
|
||||
if (window.LANGS[key].disabled) continue;
|
||||
Langs[key] = window.LANGS[key];
|
||||
|
||||
Reference in new issue
Block a user