Organize a lot of utils

This commit is contained in:
Vortrex
2022-01-09 17:19:53 -06:00
parent 2684ffae7d
commit 5dfe47a3e8
16 changed files with 905 additions and 1069 deletions

View File

@@ -68,4 +68,19 @@ function getLocaleStrings() {
return getServerData().localeStrings;
}
// ===========================================================================
function getLocaleNameFromParams(params) {
let locales = getLocales();
if(isNaN(params)) {
for(let i in locales) {
if(toLowerCase(i).indexOf(toLowerCase(params)) != -1) {
return locales[i];
}
}
}
return false;
}
// ===========================================================================