Skip to content

Commit 29c36cc

Browse files
minor condition improvement
1 parent ebe1519 commit 29c36cc

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

src/wp-includes/abilities/class-wp-users-abilities.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -211,7 +211,7 @@ private static function get_user_output_schema(): array {
211211
* @return WP_User|false The user object if found, false otherwise.
212212
*/
213213
private static function find_user( array $input ) {
214-
if ( ! empty( $input['id'] ) ) {
214+
if ( ! empty( $input['id'] ) && $input['id'] > 0 ) {
215215
return get_user_by( 'ID', (int) $input['id'] );
216216
}
217217

0 commit comments

Comments
 (0)