WordPress.org

Make WordPress Core

Changeset 38458


Ignore:
Timestamp:
08/31/2016 05:03:37 AM (3 years ago)
Author:
wonderboymusic
Message:

Multisite: use get_current_site() instead of $GLOBALS['current_site'] (stop yelling!) in a few remaining spots.

See #37699.

Location:
trunk/src
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-includes/ms-deprecated.php

    r37985 r38458  
    2929        return get_blog_details( $blog );
    3030
    31     return get_blog_details( $GLOBALS['current_site']->blog_id );
     31    return get_blog_details( get_current_site()->blog_id );
    3232}
    3333
  • trunk/src/wp-login.php

    r38424 r38458  
    337337    $message .= '<' . network_site_url("wp-login.php?action=rp&key=$key&login=" . rawurlencode($user_login), 'login') . ">\r\n";
    338338
    339     if ( is_multisite() )
    340         $blogname = $GLOBALS['current_site']->site_name;
    341     else
     339    if ( is_multisite() ) {
     340        $blogname = get_current_site()->site_name;
     341    } else {
    342342        /*
    343343         * The blogname option is escaped with esc_html on the way into the database
     
    345345         */
    346346        $blogname = wp_specialchars_decode(get_option('blogname'), ENT_QUOTES);
     347    }
    347348
    348349    $title = sprintf( __('[%s] Password Reset'), $blogname );
Note: See TracChangeset for help on using the changeset viewer.