diff options
-rw-r--r-- | core/string/translation.cpp | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/core/string/translation.cpp b/core/string/translation.cpp index 73f789b041..865937e9ce 100644 --- a/core/string/translation.cpp +++ b/core/string/translation.cpp @@ -1092,9 +1092,12 @@ Array TranslationServer::get_loaded_locales() const { ERR_FAIL_COND_V(t.is_null(), Array()); String l = t->get_locale(); - locales.push_back(l); + if (!locales.has(l)) { + locales.push_back(l); + } } + locales.sort(); return locales; } |