Skip to content

Commit

Permalink
Merge pull request #286 from team9502/dev
Browse files Browse the repository at this point in the history
fix: 구글 로그인 log 추가 [배포]
  • Loading branch information
EUNCHAEv1006 authored Jul 2, 2024
2 parents fab8896 + 8305019 commit e84bce7
Showing 1 changed file with 3 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
import org.springframework.util.LinkedMultiValueMap;
import org.springframework.util.MultiValueMap;
import org.springframework.web.client.RestTemplate;
import team9502.sinchulgwinong.domain.auth.dto.request.UserSignupRequestDTO;
import team9502.sinchulgwinong.domain.oauth.dto.request.SocialLoginRequestDTO;
import team9502.sinchulgwinong.domain.oauth.enums.SocialType;
import team9502.sinchulgwinong.domain.point.enums.SpType;
Expand Down Expand Up @@ -120,6 +121,7 @@ private String getAccessToken(String code) {
throw new RuntimeException("액세스 토큰 추출 실패", e);
}
} else {
System.out.println("Error Response: " + response.getBody());
throw new RuntimeException("액세스 토큰 요청 실패");
}
}
Expand All @@ -130,6 +132,7 @@ private User createUser(SocialLoginRequestDTO requestDTO, SocialType socialType,
.nickname(requestDTO.getNickname())
.username(requestDTO.getUsername())
.phoneNumber(requestDTO.getPhoneNumber())
.password("social_login")
.loginType(socialType)
.build();
User savedUser = userRepository.save(newUser);
Expand Down

0 comments on commit e84bce7

Please sign in to comment.