WordPress.org

Make WordPress Core


Ignore:
Timestamp:
11/16/2013 01:45:28 PM (6 years ago)
Author:
SergeyBiryukov
Message:

Use get_current_site() instead of the $current_site global in wp-admin/admin-header.php and is_main_network().

fixes #25158.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-admin/admin-header.php

    r26134 r26235  
    1313// In case admin-header.php is included in a function.
    1414global $title, $hook_suffix, $current_screen, $wp_locale, $pagenow, $wp_version,
    15     $current_site, $update_title, $total_update_count, $parent_file;
     15    $update_title, $total_update_count, $parent_file;
    1616
    1717// Catch plugins that include admin-header.php before admin.php completes.
     
    2323
    2424if ( is_network_admin() )
    25     $admin_title = sprintf( __('Network Admin: %s'), esc_html( $current_site->site_name ) );
     25    $admin_title = sprintf( __( 'Network Admin: %s' ), esc_html( get_current_site()->site_name ) );
    2626elseif ( is_user_admin() )
    27     $admin_title = sprintf( __('Global Dashboard: %s'), esc_html( $current_site->site_name ) );
     27    $admin_title = sprintf( __( 'Global Dashboard: %s' ), esc_html( get_current_site()->site_name ) );
    2828else
    2929    $admin_title = get_bloginfo( 'name' );
Note: See TracChangeset for help on using the changeset viewer.