Make WordPress Core

Changeset 56210


Ignore:
Timestamp:
07/11/2023 11:32:15 AM (22 months ago)
Author:
SergeyBiryukov
Message:

Coding Standards: Use strict comparison in wp-includes/class-wp-rewrite.php.

Follow-up to [3638], [13689], [19743].

Props aristath, poena, afercia, SergeyBiryukov.
See #57839.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-includes/class-wp-rewrite.php

    r56031 r56210  
    16691669            $front = substr( $query, 0, $index );
    16701670
    1671             $external = $front != $this->index;
     1671            $external = $front !== $this->index;
    16721672        }
    16731673
     
    18001800            $args = array( 'with_front' => $args );
    18011801        }
    1802         if ( func_num_args() == 4 ) {
     1802
     1803        if ( func_num_args() === 4 ) {
    18031804            $args['ep_mask'] = func_get_arg( 3 );
    18041805        }
     
    18131814            'endpoints'   => true,
    18141815        );
    1815         $args     = array_intersect_key( $args, $defaults );
    1816         $args     = wp_parse_args( $args, $defaults );
     1816
     1817        $args = array_intersect_key( $args, $defaults );
     1818        $args = wp_parse_args( $args, $defaults );
    18171819
    18181820        if ( $args['with_front'] ) {
     
    18211823            $struct = $this->root . $struct;
    18221824        }
     1825
    18231826        $args['struct'] = $struct;
    18241827
     
    19381941     */
    19391942    public function set_permalink_structure( $permalink_structure ) {
    1940         if ( $permalink_structure != $this->permalink_structure ) {
     1943        if ( $this->permalink_structure !== $permalink_structure ) {
    19411944            $old_permalink_structure = $this->permalink_structure;
    19421945            update_option( 'permalink_structure', $permalink_structure );
Note: See TracChangeset for help on using the changeset viewer.