Make WordPress Core


Ignore:
Timestamp:
10/02/2015 07:07:23 PM (11 years ago)
Author:
jeremyfelt
Message:

MS: Use *_network_option() functions throughout core.

Replaces all uses of *_site_option() with the corresponding "network" function.

This excludes one usage in wp-admin/admin-footer.php that needs more investigation.

Props spacedmonkey.
See #28290.

File:
1 edited

Legend:

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

    r34296 r34778  
    3030function get_core_updates( $options = array() ) {
    3131        $options = array_merge( array( 'available' => true, 'dismissed' => false ), $options );
    32         $dismissed = get_site_option( 'dismissed_update_core' );
     32        $dismissed = get_network_option( 'dismissed_update_core' );
    3333
    3434        if ( ! is_array( $dismissed ) )
    … …  
    135135 */
    136136function dismiss_core_update( $update ) {
    137         $dismissed = get_site_option( 'dismissed_update_core' );
     137        $dismissed = get_network_option( 'dismissed_update_core' );
    138138        $dismissed[ $update->current . '|' . $update->locale ] = true;
    139         return update_site_option( 'dismissed_update_core', $dismissed );
     139        return update_network_option( 'dismissed_update_core', $dismissed );
    140140}
    141141
    … …  
    147147 */
    148148function undismiss_core_update( $version, $locale ) {
    149         $dismissed = get_site_option( 'dismissed_update_core' );
     149        $dismissed = get_network_option( 'dismissed_update_core' );
    150150        $key = $version . '|' . $locale;
    151151
    … …  
    154154
    155155        unset( $dismissed[$key] );
    156         return update_site_option( 'dismissed_update_core', $dismissed );
     156        return update_network_option( 'dismissed_update_core', $dismissed );
    157157}
    158158
    … …  
    479479        $nag = isset( $upgrading );
    480480        if ( ! $nag ) {
    481                 $failed = get_site_option( 'auto_core_update_failed' );
     481                $failed = get_network_option( 'auto_core_update_failed' );
    482482                /*
    483483                 * If an update failed critically, we may have copied over version.php but not other files.
Note: See TracChangeset for help on using the changeset viewer.