mirror of
https://gitcode.com/gh_mirrors/hy/Hydro.git
synced 2026-10-20 01:38:19 +08:00
core: problem.del, ignore upgrade on fresh install
This commit is contained in:
1 parent
1543a374e3
commit
1d3bdacde9
12 files changed
+66
-119
No files matched your search
@@ -46,12 +46,8 @@ String.prototype.translate = function translate(...languages: string[]) {
|
||||
languages.push(global.Hydro.model.system.get('server.language'));
|
||||
for (const language of languages) {
|
||||
if (!language) continue;
|
||||
if (locales[language]) {
|
||||
if (locales[language][this] !== undefined) return locales[language][this];
|
||||
}
|
||||
if (locales[language.split('_')[0]]) {
|
||||
if (locales[language.split('_')[0]][this] !== undefined) return locales[language.split('_')[0]][this];
|
||||
}
|
||||
const curr = (locales[language] || {})[this] || (locales[language.split('_')[0]] || {})[this];
|
||||
if (curr) return curr;
|
||||
}
|
||||
return this;
|
||||
};
|
||||
|
||||
Reference in new issue
Block a user