Change language behavior; change _ to - and lowercase langs.
This commit is contained in:
parent
8288ebc67a
commit
dc7f0025ef
32 changed files with 2 additions and 2 deletions
|
@ -1,12 +1,12 @@
|
|||
<?php
|
||||
|
||||
function loadLocale($lang = 'en_US') {
|
||||
function loadLocale($lang = 'en-us') {
|
||||
$file = __DIR__ . '/../locale/' . $lang . '/messages.php';
|
||||
if (file_exists($file)) {
|
||||
return require $file;
|
||||
} else {
|
||||
// Fallback to English if the specified language file does not exist
|
||||
return require __DIR__ . '/../locale/en_US/messages.php';
|
||||
return require __DIR__ . '/../locale/en-us/messages.php';
|
||||
}
|
||||
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue