From dcc82c39ccfc4d0aef8751b317724fea0c27b40f Mon Sep 17 00:00:00 2001 From: Sergey Biryukov Date: Fri, 28 Jul 2023 11:37:25 +0000 Subject: [PATCH] Coding Standards: Use strict comparison in `wp-includes/class-wp-roles.php`. Follow-up to [25695], [41625]. Props aristath, poena, afercia, SergeyBiryukov. See #58831. Built from https://develop.svn.wordpress.org/trunk@56321 git-svn-id: http://core.svn.wordpress.org/trunk@55833 1a063a9b-81f0-0310-95a4-ce76da25c4cd --- wp-includes/class-wp-roles.php | 4 ++-- wp-includes/version.php | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/wp-includes/class-wp-roles.php b/wp-includes/class-wp-roles.php index f224250fa2..245aa2b05a 100644 --- a/wp-includes/class-wp-roles.php +++ b/wp-includes/class-wp-roles.php @@ -192,7 +192,7 @@ class WP_Roles { update_option( $this->role_key, $this->roles ); } - if ( get_option( 'default_role' ) == $role ) { + if ( get_option( 'default_role' ) === $role ) { update_option( 'default_role', 'subscriber' ); } } @@ -359,7 +359,7 @@ class WP_Roles { return $wp_user_roles; } - if ( is_multisite() && get_current_blog_id() != $this->site_id ) { + if ( is_multisite() && get_current_blog_id() !== $this->site_id ) { remove_action( 'switch_blog', 'wp_switch_roles_and_user', 1 ); $roles = get_blog_option( $this->site_id, $this->role_key, array() ); diff --git a/wp-includes/version.php b/wp-includes/version.php index c7dcd798cd..a4b99a742e 100644 --- a/wp-includes/version.php +++ b/wp-includes/version.php @@ -16,7 +16,7 @@ * * @global string $wp_version */ -$wp_version = '6.4-alpha-56320'; +$wp_version = '6.4-alpha-56321'; /** * Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.