From 59a793ac9d00c408791192cbf89b87f6caddfc44 Mon Sep 17 00:00:00 2001 From: Sergey Biryukov Date: Tue, 11 Jul 2023 11:15:27 +0000 Subject: [PATCH] Coding Standards: Use strict comparison in `wp-includes/rewrite.php`. Follow-up to [6614], [13689], [19743]. Props aristath, poena, afercia, SergeyBiryukov. See #57839. Built from https://develop.svn.wordpress.org/trunk@56208 git-svn-id: http://core.svn.wordpress.org/trunk@55720 1a063a9b-81f0-0310-95a4-ce76da25c4cd --- wp-includes/rewrite.php | 5 +++-- wp-includes/version.php | 2 +- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/wp-includes/rewrite.php b/wp-includes/rewrite.php index b76de4c136..647977cc20 100644 --- a/wp-includes/rewrite.php +++ b/wp-includes/rewrite.php @@ -210,7 +210,8 @@ function add_permastruct( $name, $struct, $args = array() ) { if ( ! is_array( $args ) ) { $args = array( 'with_front' => $args ); } - if ( func_num_args() == 4 ) { + + if ( func_num_args() === 4 ) { $args['ep_mask'] = func_get_arg( 3 ); } @@ -602,7 +603,7 @@ function url_to_postid( $url ) { * If the requesting file is the anchor of the match, * prepend it to the path info. */ - if ( ! empty( $url ) && ( $url != $request ) && str_starts_with( $match, $url ) ) { + if ( ! empty( $url ) && ( $url !== $request ) && str_starts_with( $match, $url ) ) { $request_match = $url . '/' . $request; } diff --git a/wp-includes/version.php b/wp-includes/version.php index 4c671161da..8cdf256d1b 100644 --- a/wp-includes/version.php +++ b/wp-includes/version.php @@ -16,7 +16,7 @@ * * @global string $wp_version */ -$wp_version = '6.3-beta3-56207'; +$wp_version = '6.3-beta3-56208'; /** * Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.