Make WordPress Core


Ignore:
Timestamp:
10/17/2013 11:20:56 PM (11 years ago)
Author:
nacin
Message:

In automatic background updates, standardize on 'update'.

New, final filter names:

  • auto_update_{$type} (plugin, theme, core, language)
  • automatic_updates_is_vcs_checkout
  • automatic_updates_disabled

New class name is WP_Automatic_Updater. Method names include update() and should_update().

see #22704.

File:
1 edited

Legend:

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

    r25823 r25835  
    149149        if ( wp_http_supports( 'ssl' ) ) {
    150150            require_once ABSPATH . 'wp-admin/includes/class-wp-upgrader.php';
    151             $upgrader = new WP_Automatic_Upgrader;
     151            $upgrader = new WP_Automatic_Updater;
    152152            $future_minor_update = (object) array(
    153153                'current'       => $wp_version . '.1-update-core.php',
     
    156156                'mysql_version' => $required_mysql_version,
    157157            );
    158             $should_auto_update = $upgrader->should_upgrade( 'core', $future_minor_update, ABSPATH );
     158            $should_auto_update = $upgrader->should_update( 'core', $future_minor_update, ABSPATH );
    159159            if ( $should_auto_update )
    160160                echo ' ' . __( 'Future security updates will be applied automatically.' );
     
    173173    if ( isset( $updates[0] ) && $updates[0]->response == 'development' ) {
    174174        require_once ABSPATH . 'wp-admin/includes/class-wp-upgrader.php';
    175         $upgrader = new WP_Automatic_Upgrader;
    176         if ( wp_http_supports( 'ssl' ) && $upgrader->should_upgrade( 'core', $updates[0], ABSPATH ) )
     175        $upgrader = new WP_Automatic_Updater;
     176        if ( wp_http_supports( 'ssl' ) && $upgrader->should_update( 'core', $updates[0], ABSPATH ) )
    177177            echo '<div class="updated inline"><p><strong>BETA TESTERS:</strong> This site is set up to install updates of future beta versions automatically.</p></div>';
    178178    }
Note: See TracChangeset for help on using the changeset viewer.