Skip to content

Commit

Permalink
Correctly check that the user actually has the meta key
Browse files Browse the repository at this point in the history
  • Loading branch information
psrpinto committed Sep 14, 2023
1 parent 92cc419 commit 3403c9b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Storage/AuthorizationCodeStorage.php
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ private function getUserIdByCode( $code ) {
$user = $users[0];

// Double-check that the user actually has the meta key.
if ( false === get_user_meta( $user, $key, true ) ) {
if ( '' === get_user_meta( $user, $key, true ) ) {
return null;
}

Expand Down

0 comments on commit 3403c9b

Please sign in to comment.