Make WordPress Core

Changeset 36505


Ignore:
Timestamp:
02/09/2016 02:29:06 PM (9 years ago)
Author:
ocean90
Message:

Multisite: Don't show the database upgrade admin notice on the upgrade page itself.

Fixes #35782.

File:
1 edited

Legend:

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

    r36504 r36505  
    749749 * @since 3.0.0
    750750 *
    751  * @global int $wp_db_version The version number of the database.
     751 * @global int    $wp_db_version The version number of the database.
     752 * @global string $pagenow
    752753 *
    753754 * @return false False if the current user is not a super admin.
    754755 */
    755756function site_admin_notice() {
    756     global $wp_db_version;
    757     if ( !is_super_admin() )
     757    global $wp_db_version, $pagenow;
     758
     759    if ( ! is_super_admin() ) {
    758760        return false;
    759     if ( get_site_option( 'wpmu_upgrade_site' ) != $wp_db_version )
     761    }
     762
     763    if ( 'upgrade.php' == $pagenow ) {
     764        return;
     765    }
     766
     767    if ( get_site_option( 'wpmu_upgrade_site' ) != $wp_db_version ) {
    760768        echo "<div class='update-nag'>" . sprintf( __( 'Thank you for Updating! Please visit the <a href="%s">Upgrade Network</a> page to update all your sites.' ), esc_url( network_admin_url( 'upgrade.php' ) ) ) . "</div>";
     769    }
    761770}
    762771
Note: See TracChangeset for help on using the changeset viewer.