mirror of
https://github.com/spring-projects/spring-security.git
synced 2025-06-24 04:52:16 +00:00
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:
parent
4e20d56d2d
commit
593f7c4490
@ -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());
|
||||
|
Loading…
x
Reference in New Issue
Block a user