Make WordPress Core


Ignore:
Timestamp:
04/05/2021 10:36:17 AM (4 years ago)
Author:
SergeyBiryukov
Message:

Coding Standards: Use strict comparison in wp-admin/includes/class-wp-filesystem-*.php.

See #52627.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-admin/includes/class-wp-filesystem-ftpext.php

    r49936 r50657  
    451451        $result = @ftp_chdir( $this->link, trailingslashit( $path ) );
    452452
    453         if ( $result && $path == $this->cwd() || $this->cwd() != $cwd ) {
     453        if ( $result && $path === $this->cwd() || $this->cwd() !== $cwd ) {
    454454            @ftp_chdir( $this->link, $cwd );
    455455            return true;
     
    615615            $b['hour']   = $lucifer[4];
    616616            $b['minute'] = $lucifer[5];
    617             $b['time']   = mktime( $lucifer[4] + ( strcasecmp( $lucifer[6], 'PM' ) == 0 ? 12 : 0 ), $lucifer[5], 0, $lucifer[1], $lucifer[2], $lucifer[3] );
     617            $b['time']   = mktime( $lucifer[4] + ( strcasecmp( $lucifer[6], 'PM' ) === 0 ? 12 : 0 ), $lucifer[5], 0, $lucifer[1], $lucifer[2], $lucifer[3] );
    618618            $b['am/pm']  = $lucifer[6];
    619619            $b['name']   = $lucifer[8];
     
    648648                $b['size']   = $lucifer[4];
    649649
    650                 if ( 8 == $lcount ) {
     650                if ( 8 === $lcount ) {
    651651                    sscanf( $lucifer[5], '%d-%d-%d', $b['year'], $b['month'], $b['day'] );
    652652                    sscanf( $lucifer[6], '%d:%d', $b['hour'], $b['minute'] );
     
    746746            }
    747747
    748             if ( $limit_file && $entry['name'] != $limit_file ) {
     748            if ( $limit_file && $entry['name'] !== $limit_file ) {
    749749                continue;
    750750            }
Note: See TracChangeset for help on using the changeset viewer.