fix(settings): show the correct initial locale in Personal info

Signed-off-by: Josh <josh.t.richards@gmail.com>
pull/50071/head
Josh 2024-12-29 12:33:29 +07:00 committed by Andy Scherzinger
parent cfd31b4f13
commit cb4c2adafa
1 changed files with 1 additions and 1 deletions

@ -324,8 +324,8 @@ class PersonalInfo implements ISettings {
}
$uid = $user->getUID();
$userLocaleString = $this->config->getUserValue($uid, 'core', 'locale', $this->l10nFactory->findLocale());
$userLang = $this->config->getUserValue($uid, 'core', 'lang', $this->l10nFactory->findLanguage());
$userLocaleString = $this->config->getUserValue($uid, 'core', 'locale', $this->l10nFactory->findLocale($userLang));
$localeCodes = $this->l10nFactory->findAvailableLocales();
$userLocale = array_filter($localeCodes, fn ($value) => $userLocaleString === $value['code']);