2252 | | // Clean up the `post_category` column removed from schema in version 2.8.0. |
2253 | | // Its presence may conflict with WP_Post::__get(). |
2254 | | $post_category_exists = $wpdb->get_var( "SHOW COLUMNS FROM $wpdb->posts LIKE 'post_category'" ); |
2255 | | if ( ! is_null( $post_category_exists ) ) { |
2256 | | $wpdb->query( "ALTER TABLE $wpdb->posts DROP COLUMN `post_category`" ); |
| 2252 | if ( $wp_current_db_version < 49572 ) { |
| 2253 | /* |
| 2254 | * Clean up the `post_category` column removed from schema in version 2.8.0. |
| 2255 | * Its presence may conflict with `WP_Post::__get()`. |
| 2256 | */ |
| 2257 | $post_category_exists = $wpdb->get_var( "SHOW COLUMNS FROM $wpdb->posts LIKE 'post_category'" ); |
| 2258 | if ( ! is_null( $post_category_exists ) ) { |
| 2259 | $wpdb->query( "ALTER TABLE $wpdb->posts DROP COLUMN `post_category`" ); |
| 2260 | } |
| 2261 | |
| 2262 | /* |
| 2263 | * When upgrading from WP < 5.6.0 set the core major auto-updates option to `unset` by default. |
| 2264 | * This overrides the same option from populate_options() that is intended for new installs. |
| 2265 | * See https://core.trac.wordpress.org/ticket/51742. |
| 2266 | */ |
| 2267 | update_option( 'auto_update_core_major', 'unset' ); |
2259 | | // When upgrading from WP < 5.6.0 set the core major auto-updates option to `unset` by default. |
2260 | | // This overrides the same option from populate_options() that is intended for new installs. |
2261 | | // See https://core.trac.wordpress.org/ticket/51742. |
2262 | | update_option( 'auto_update_core_major', 'unset' ); |
| 2270 | if ( $wp_current_db_version < 49602 ) { |
| 2271 | /* |
| 2272 | * Regenerate the .htaccess file to add the `HTTP_AUTHORIZATION` rewrite rule. |
| 2273 | * See https://core.trac.wordpress.org/ticket/51723. |
| 2274 | */ |
| 2275 | save_mod_rewrite_rules(); |
| 2276 | } |