WordPress.org

Make WordPress Core

Ticket #14764: 14764.1.patch

File 14764.1.patch, 1.1 KB (added by simontaotw, 4 years ago)
  • wp-admin/update-core.php

     
    110110 * 
    111111 * @return null 
    112112 */ 
    113 function core_upgrade_preamble() { 
     113function core_upgrade_preamble($checked_time) { 
    114114        global $upgrade_error; 
    115115 
    116116        $updates = get_core_updates(); 
     
    138138                _e( 'An updated version of WordPress is available.' ); 
    139139                echo '</h3>'; 
    140140        } 
     141        echo '<em>'; 
     142        echo sprintf(__('Last checked at %s'), $checked_time); 
     143        echo '</em>'; 
    141144 
    142145        echo '<ul class="core-updates">'; 
    143146        $alternate = true; 
     
    391394); 
    392395 
    393396if ( 'upgrade-core' == $action ) { 
    394         wp_version_check(); 
     397        $version_check_result = wp_version_check(); 
     398        if ( null == $version_check_result || false == $version_check_result || true == $version_check_result ) 
     399                $checked_time = current_time('mysql'); 
    395400        require_once('./admin-header.php'); 
    396         core_upgrade_preamble(); 
     401        core_upgrade_preamble($checked_time); 
    397402} elseif ( 'do-core-upgrade' == $action || 'do-core-reinstall' == $action ) { 
    398403        check_admin_referer('upgrade-core'); 
    399404