WordPress.org

Make WordPress Core

Ticket #51774: 51774.3.diff

File 51774.3.diff, 1.2 KB (added by afragen, 10 months ago)

changed button to be 'Re-install version x.x.x'

  • wp-admin/update-core.php

    diff --git a/wp-admin/update-core.php b/wp-admin/update-core.php
    index 5a4a8d369f..b7b3c9fad5 100644
    a b function list_core_update( $update ) { 
    5555                $current = true;
    5656        }
    5757
    58         $submit        = __( 'Update Now' );
     58        preg_match( '/(alpha|beta|RC)(\d+)/', $version_string, $nightly );
     59        $submit        = ! empty( $nightly ) ? __( 'Update to latest nightly' ) : __( 'Update Now' );
    5960        $form_action   = 'update-core.php?action=do-core-upgrade';
    6061        $php_version   = phpversion();
    6162        $mysql_version = $wpdb->db_version();
    function list_core_update( $update ) { 
    6566                $message = __( 'You are using a development version of WordPress. You can update to the latest nightly build manually:' );
    6667        } else {
    6768                if ( $current ) {
     69                        $message = '';
    6870                        /* translators: %s: WordPress version. */
    69                         $message     = sprintf( __( 'If you need to re-install version %s, you can do so here:' ), $version_string );
    70                         $submit      = __( 'Re-install Now' );
     71                        $submit      = sprintf( __( 'Re-install version %s' ), $version_string );
    7172                        $form_action = 'update-core.php?action=do-core-reinstall';
    7273                } else {
    7374                        $php_compat = version_compare( $php_version, $update->php_version, '>=' );