WordPress.org

Make WordPress Core


Ignore:
Timestamp:
12/16/2010 09:31:42 AM (10 years ago)
Author:
nacin
Message:

Make network_admin_url() return admin_url() when not multisite like its home and site counterparts. Kill the now redundant maybe_network_admin_url() function. fixes #15840.

File:
1 edited

Legend:

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

    r16978 r16994  
    101101    switch ( $cur->response ) {
    102102    case 'development' :
    103         return sprintf( __( 'You are using a development version (%1$s). Cool! Please <a href="%2$s">stay updated</a>.' ), $GLOBALS['wp_version'], maybe_network_admin_url( 'update-core.php' ) );
     103        return sprintf( __( 'You are using a development version (%1$s). Cool! Please <a href="%2$s">stay updated</a>.' ), $GLOBALS['wp_version'], network_admin_url( 'update-core.php' ) );
    104104    break;
    105105
    106106    case 'upgrade' :
    107         return sprintf( '<strong>'.__( '<a href="%1$s">Get Version %2$s</a>' ).'</strong>', maybe_network_admin_url( 'update-core.php' ), $cur->current);
     107        return sprintf( '<strong>'.__( '<a href="%1$s">Get Version %2$s</a>' ).'</strong>', network_admin_url( 'update-core.php' ), $cur->current);
    108108    break;
    109109
     
    131131
    132132    if ( current_user_can('update_core') ) {
    133         $msg = sprintf( __('<a href="http://codex.wordpress.org/Version_%1$s">WordPress %1$s</a> is available! <a href="%2$s">Please update now</a>.'), $cur->current, maybe_network_admin_url( 'update-core.php' ) );
     133        $msg = sprintf( __('<a href="http://codex.wordpress.org/Version_%1$s">WordPress %1$s</a> is available! <a href="%2$s">Please update now</a>.'), $cur->current, network_admin_url( 'update-core.php' ) );
    134134    } else {
    135135        $msg = sprintf( __('<a href="http://codex.wordpress.org/Version_%1$s">WordPress %1$s</a> is available! Please notify the site administrator.'), $cur->current );
     
    149149
    150150    if ( isset( $cur->response ) && $cur->response == 'upgrade' && current_user_can('update_core') ) {
    151         $msg .= " <a href='" . maybe_network_admin_url( 'update-core.php' ) . "' class='button'>" . sprintf( __('Update to %s'), $cur->current ? $cur->current : __( 'Latest' ) ) . '</a>';
     151        $msg .= " <a href='" . network_admin_url( 'update-core.php' ) . "' class='button'>" . sprintf( __('Update to %s'), $cur->current ? $cur->current : __( 'Latest' ) ) . '</a>';
    152152    }
    153153
Note: See TracChangeset for help on using the changeset viewer.