Skip to content

Commit bf60ecf

Browse files
committed
Fix:레코드관련
1 parent a846293 commit bf60ecf

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

back/src/main/java/com/back/global/security/oauth2/CustomOAuth2UserService.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -37,15 +37,15 @@ public OAuth2User loadUser(OAuth2UserRequest req) throws OAuth2AuthenticationExc
3737

3838
OAuthAttributes attrs = OAuthAttributes.of(registrationId, userNameAttr, raw.getAttributes());
3939

40-
String email = attrs.getEmail();
40+
String email = attrs.email();
4141
if (email == null || email.isBlank()) {
4242
throw new OAuth2AuthenticationException(
4343
new OAuth2Error("email_not_found", "OAuth2 제공자로부터 이메일을 받을 수 없습니다.", null)
4444
);
4545
}
4646

4747
AuthProvider provider = AuthProvider.valueOf(registrationId.toUpperCase());
48-
User user = userService.upsertOAuthUser(email, attrs.getName(), provider);
48+
User user = userService.upsertOAuthUser(email, attrs.name(), provider);
4949

5050
return new CustomUserDetails(user, raw.getAttributes());
5151

0 commit comments

Comments
 (0)