WordPress.org

Make WordPress Core

Changeset 45106


Ignore:
Timestamp:
04/03/2019 02:13:31 AM (6 months ago)
Author:
SergeyBiryukov
Message:

PHPCS: Fix WPCS violations in [45104].

See #46645.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-admin/includes/class-wp-debug-data.php

    r45104 r45106  
    331331        // When testing 20 seconds seem enough in nearly all cases. The remaining edge cases are likely testing or development sites
    332332        // that have very large number of files, for example `node_modules` in plugins or themes, etc.
    333         if ( $max_execution_time > 20  ) {
     333        if ( $max_execution_time > 20 ) {
    334334            $max_execution_time = 20;
    335335        } elseif ( $max_execution_time > 2 ) {
     
    358358        );
    359359
    360         $timeout = __( 'The directory size calculation has timed out. Usually caused by a very large number of sub-directories and files.' );
     360        $timeout      = __( 'The directory size calculation has timed out. Usually caused by a very large number of sub-directories and files.' );
    361361        $inaccessible = __( 'The size cannot be calculated. The directory is not accessible. Usually caused by invalid permissions.' );
    362         $size_total = 0;
     362        $size_total   = 0;
    363363
    364364        // Loop over all the directories we want to gather the sizes for.
     
    372372            if ( $dir_size === false ) {
    373373                // Error reading
    374                 $dir_size = $inaccessible;
     374                $dir_size   = $inaccessible;
    375375                $size_total = null;
    376376            } elseif ( $dir_size === null ) {
    377377                // Timeout
    378                 $dir_size = $timeout;
     378                $dir_size   = $timeout;
    379379                $size_total = null;
    380380            } else {
    381381                $is_subdir = ( strpos( $size_directories[ $size ]['path'], ABSPATH ) === 0 );
    382382
     383                // phpcs:ignore WordPress.WP.CapitalPDangit.Misspelled
    383384                if ( $size_total !== null && ( $size === 'wordpress' || ! $is_subdir ) ) {
    384385                    $size_total += $dir_size;
Note: See TracChangeset for help on using the changeset viewer.