Use "toISO6391" instead of "substr"

This commit is contained in:
Michael 2023-11-03 05:32:57 +00:00
parent 90e05fd835
commit a7ab14b3b3
3 changed files with 11 additions and 3 deletions

View file

@ -242,7 +242,7 @@ class Temporal
// First day of the week (0 = Sunday)
$firstDay = DI::pConfig()->get(DI::userSession()->getLocalUserId(), 'calendar', 'first_day_of_week', 0);
$lang = substr(DI::l10n()->getCurrentLang(), 0, 2);
$lang = DI::l10n()->toISO6391(DI::l10n()->getCurrentLang());
// Check if the detected language is supported by the picker
if (!in_array($lang,