Use !isAuthenticated
It's more verbose to see if the user is not null and not anonymous Issue gh-16385
This commit is contained in:
+1
-1
@@ -345,7 +345,7 @@ public class Webauthn4JRelyingPartyOperations implements WebAuthnRelyingPartyOpe
|
||||
}
|
||||
|
||||
private List<CredentialRecord> findCredentialRecords(Authentication authentication) {
|
||||
if (authentication == null || this.trustResolver.isAnonymous(authentication)) {
|
||||
if (!this.trustResolver.isAuthenticated(authentication)) {
|
||||
return Collections.emptyList();
|
||||
}
|
||||
PublicKeyCredentialUserEntity userEntity = this.userEntities.findByUsername(authentication.getName());
|
||||
|
||||
Reference in New Issue
Block a user