Changeset 39169 for trunk/src/wp-admin/includes/user.php
- Timestamp:
- 11/08/2016 11:00:38 PM (8 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-admin/includes/user.php
r38705 r39169 99 99 if ( isset( $_POST['locale'] ) ) { 100 100 $locale = sanitize_text_field( $_POST['locale'] ); 101 if ( ! in_array( $locale, get_available_languages(), true )) {101 if ( 'site-default' === $locale ) { 102 102 $locale = ''; 103 } elseif ( ! in_array( $locale, get_available_languages(), true ) ) { 104 $locale = 'en_US'; 103 105 } 104 106 105 $user->locale = ( '' === $locale ) ? 'en_US' :$locale;107 $user->locale = $locale; 106 108 } 107 109 }
Note: See TracChangeset
for help on using the changeset viewer.