mirror of
https://github.com/gosticks/wordpress-develop.git
synced 2026-06-28 22:30:04 +00:00
I18N: Always pass $locale to load_textdomain().
In [53874] the optional `$locale` parameter was added to `load_textdomain()`. While most `load_textdomain()` calls in core were were updated, some were missed. Passing the original locale avoids the need to call `determine_locale()` by `load_textdomain()` which is used as a fallback. Props ocean90, swissspidy, desrosj. See #57060. git-svn-id: https://develop.svn.wordpress.org/trunk@54797 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
@@ -6351,7 +6351,7 @@ function wp_timezone_choice( $selected_zone, $locale = null ) {
|
||||
$locale_loaded = $locale ? $locale : get_locale();
|
||||
$mofile = WP_LANG_DIR . '/continents-cities-' . $locale_loaded . '.mo';
|
||||
unload_textdomain( 'continents-cities' );
|
||||
load_textdomain( 'continents-cities', $mofile );
|
||||
load_textdomain( 'continents-cities', $mofile, $locale_loaded );
|
||||
$mo_loaded = true;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user