Make WordPress Core

Ticket #59297: 59297.7.patch

File 59297.7.patch, 1.3 KB (added by viralsampat, 18 months ago)

I have checked above mentioned issue and founds few files. Here, I have added its patch.

  • src/wp-includes/ms-settings.php

    diff --git src/wp-includes/ms-settings.php src/wp-includes/ms-settings.php
    index 6824895880..af1a9c955d 100644
    if ( ! isset( $current_site ) || ! isset( $current_blog ) ) { 
    8181        }
    8282        unset( $bootstrap_result );
    8383
    84         $blog_id = $current_blog->blog_id;
    8584        $public  = $current_blog->public;
    8685
    8786        if ( empty( $current_blog->site_id ) ) {
    if ( ! isset( $current_site ) || ! isset( $current_blog ) ) { 
    9796$wpdb->set_prefix( $table_prefix, false ); // $table_prefix can be set in sunrise.php.
    9897$wpdb->set_blog_id( $current_blog->blog_id, $current_blog->site_id );
    9998$table_prefix       = $wpdb->get_blog_prefix();
    100 $_wp_switched_stack = array();
    101 $switched           = false;
    10299
    103100// Need to init cache again after blog_id is set.
    104101wp_start_object_cache();
  • src/wp-includes/rest-api/class-wp-rest-server.php

    diff --git src/wp-includes/rest-api/class-wp-rest-server.php src/wp-includes/rest-api/class-wp-rest-server.php
    index 1690a00eb8..3830ab5670 100644
    class WP_REST_Server { 
    10621062
    10631063                        foreach ( $handlers as $handler ) {
    10641064                                $callback = $handler['callback'];
    1065                                 $response = null;
    10661065
    10671066                                // Fallback to GET method if no HEAD method is registered.
    10681067                                $checked_method = $method;