Make WordPress Core


Ignore:
Timestamp:
07/01/2019 12:50:14 PM (6 years ago)
Author:
pento
Message:

Coding Standards: Fix the Squiz.PHP.DisallowMultipleAssignments violations in wp-admin.

See #47632.

File:
1 edited

Legend:

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

    r45532 r45583  
    3636    static $first_pass = true;
    3737
    38     $wp_version = get_bloginfo( 'version' );
     38    $wp_version     = get_bloginfo( 'version' );
     39    $version_string = sprintf( '%s&ndash;<strong>%s</strong>', $update->current, $update->locale );
    3940
    4041    if ( 'en_US' == $update->locale && 'en_US' == get_locale() ) {
    4142        $version_string = $update->current;
    42     } elseif ( 'en_US' == $update->locale && $update->packages->partial && $wp_version == $update->partial_version && ( $updates = get_core_updates() ) && 1 == count( $updates ) ) {
    43         // If the only available update is a partial builds, it doesn't need a language-specific version string.
    44         $version_string = $update->current;
    45     } else {
    46         $version_string = sprintf( '%s&ndash;<strong>%s</strong>', $update->current, $update->locale );
     43    } elseif ( 'en_US' == $update->locale && $update->packages->partial && $wp_version == $update->partial_version ) {
     44        $updates = get_core_updates();
     45        if ( $updates && 1 == count( $updates ) ) {
     46            // If the only available update is a partial builds, it doesn't need a language-specific version string.
     47            $version_string = $update->current;
     48        }
    4749    }
    4850
     
    538540    <?php
    539541
    540     if ( false === ( $credentials = request_filesystem_credentials( $url, '', false, ABSPATH, array( 'version', 'locale' ), $allow_relaxed_file_ownership ) ) ) {
     542    $credentials = request_filesystem_credentials( $url, '', false, ABSPATH, array( 'version', 'locale' ), $allow_relaxed_file_ownership );
     543    if ( false === $credentials ) {
    541544        echo '</div>';
    542545        return;
Note: See TracChangeset for help on using the changeset viewer.