Coding Standards: Remove extra conditional in `is_super_admin()`.

Follow-up to [12612].

Props dhruvang21, ankit-k-gupta, audrasjb.
Fixes #61098.
Built from https://develop.svn.wordpress.org/trunk@58099


git-svn-id: http://core.svn.wordpress.org/trunk@57564 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
Sergey Biryukov 2024-05-05 14:35:19 +00:00
parent d2434ccaa9
commit 0b17c7e5f4
2 changed files with 3 additions and 5 deletions

View File

@ -1088,10 +1088,8 @@ function is_super_admin( $user_id = false ) {
if ( is_array( $super_admins ) && in_array( $user->user_login, $super_admins, true ) ) {
return true;
}
} else {
if ( $user->has_cap( 'delete_users' ) ) {
return true;
}
} elseif ( $user->has_cap( 'delete_users' ) ) {
return true;
}
return false;

View File

@ -16,7 +16,7 @@
*
* @global string $wp_version
*/
$wp_version = '6.6-alpha-58098';
$wp_version = '6.6-alpha-58099';
/**
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.