Some hosting providers may disable putenv for security reasons, check before using

This commit is contained in:
2025-04-04 11:12:57 +03:00
parent 39e3018222
commit b8eeda6023

View File

@ -4897,7 +4897,9 @@ function load_lang(): void
} }
} }
} }
putenv('LC_ALL='.$locale); if(function_exists('putenv')) {
putenv('LC_ALL='.$locale);
}
setlocale(LC_ALL, $locale); setlocale(LC_ALL, $locale);
bindtextdomain('le-chat-php', __DIR__.'/locale'); bindtextdomain('le-chat-php', __DIR__.'/locale');
bind_textdomain_codeset('le-chat-php', 'UTF-8'); bind_textdomain_codeset('le-chat-php', 'UTF-8');