Changeset 47550 for trunk/src/wp-admin/includes/upgrade.php
- Timestamp:
- 04/05/2020 03:00:44 AM (5 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-admin/includes/upgrade.php
r47280 r47550 1914 1914 if ( $wp_current_db_version < 29630 ) { 1915 1915 if ( ! is_multisite() && false === get_option( 'WPLANG' ) ) { 1916 if ( defined( 'WPLANG' ) && ( '' !== WPLANG ) && in_array( WPLANG, get_available_languages() ) ) {1916 if ( defined( 'WPLANG' ) && ( '' !== WPLANG ) && in_array( WPLANG, get_available_languages(), true ) ) { 1917 1917 update_option( 'WPLANG', WPLANG ); 1918 1918 } else { … … 2636 2636 foreach ( $cqueries as $table => $qry ) { 2637 2637 // Upgrade global tables only for the main site. Don't upgrade at all if conditions are not optimal. 2638 if ( in_array( $table, $global_tables ) && ! wp_should_upgrade_global_tables() ) {2638 if ( in_array( $table, $global_tables, true ) && ! wp_should_upgrade_global_tables() ) { 2639 2639 unset( $cqueries[ $table ], $for_update[ $table ] ); 2640 2640 continue; … … 2800 2800 if ( $tablefield->Type != $fieldtype ) { 2801 2801 $do_change = true; 2802 if ( in_array( $fieldtype_lowercased, $text_fields ) && in_array( $tablefield_type_lowercased, $text_fields) ) {2803 if ( array_search( $fieldtype_lowercased, $text_fields ) < array_search( $tablefield_type_lowercased, $text_fields) ) {2802 if ( in_array( $fieldtype_lowercased, $text_fields, true ) && in_array( $tablefield_type_lowercased, $text_fields, true ) ) { 2803 if ( array_search( $fieldtype_lowercased, $text_fields, true ) < array_search( $tablefield_type_lowercased, $text_fields, true ) ) { 2804 2804 $do_change = false; 2805 2805 } 2806 2806 } 2807 2807 2808 if ( in_array( $fieldtype_lowercased, $blob_fields ) && in_array( $tablefield_type_lowercased, $blob_fields) ) {2809 if ( array_search( $fieldtype_lowercased, $blob_fields ) < array_search( $tablefield_type_lowercased, $blob_fields) ) {2808 if ( in_array( $fieldtype_lowercased, $blob_fields, true ) && in_array( $tablefield_type_lowercased, $blob_fields, true ) ) { 2809 if ( array_search( $fieldtype_lowercased, $blob_fields, true ) < array_search( $tablefield_type_lowercased, $blob_fields, true ) ) { 2810 2810 $do_change = false; 2811 2811 } … … 2902 2902 2903 2903 // Check if the index definition exists, ignoring subparts. 2904 $aindex = array_search( $index_string, $indices_without_subparts );2904 $aindex = array_search( $index_string, $indices_without_subparts, true ); 2905 2905 if ( false !== $aindex ) { 2906 2906 // If the index already exists (even with different subparts), we don't need to create it. … … 3246 3246 foreach ( (array) $plugins as $plugin ) { 3247 3247 if ( basename( $plugin ) == 'widgets.php' ) { 3248 array_splice( $plugins, array_search( $plugin, $plugins ), 1 );3248 array_splice( $plugins, array_search( $plugin, $plugins, true ), 1 ); 3249 3249 update_option( 'active_plugins', $plugins ); 3250 3250 break;
Note: See TracChangeset
for help on using the changeset viewer.