Skip to content

Commit 37b9254

Browse files
committed
hotfix : 구글/카카오 가져오는 정보 범위 설정
1 parent a8a56da commit 37b9254

File tree

4 files changed

+3
-9
lines changed

4 files changed

+3
-9
lines changed

greatjourney/src/main/java/backend/greatjourney/domain/user/dto/response/GoogleUserResponse.java

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,5 +20,4 @@ public class GoogleUserResponse {
2020
@JsonAlias({"email_verified", "verified_email"})
2121
private Boolean emailVerified;
2222

23-
private String picture;
2423
}

greatjourney/src/main/java/backend/greatjourney/domain/user/dto/response/KakaoUserResponse.java

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,6 @@
1111
public class KakaoUserResponse {
1212
private Long id;
1313
private KakaoAccount kakao_account;
14-
private Properties properties;
1514

1615
@Getter
1716
@Setter
@@ -20,10 +19,4 @@ public static class KakaoAccount {
2019
private String email;
2120
}
2221

23-
@Getter
24-
@Setter
25-
@JsonIgnoreProperties(ignoreUnknown = true)
26-
public static class Properties {
27-
private String nickname;
28-
}
2922
}

greatjourney/src/main/java/backend/greatjourney/domain/user/service/GoogleService.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ private GoogleUserResponse getUserInfo(String accessToken) {
5959
throw new CustomException(ErrorCode.USER_NOT_FOUND);
6060
}
6161
} catch (Exception e) {
62-
throw new CustomException(ErrorCode.KAKAO_USER_ERROR);
62+
throw new CustomException(ErrorCode.GOOGLE_USER_NOT_FOUND);
6363
}
6464
}
6565

greatjourney/src/main/java/backend/greatjourney/global/exception/ErrorCode.java

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,8 @@ public enum ErrorCode {
3737
PLACE_NOT_FOUND(HttpStatus.NOT_FOUND, 404, "해당 장소를 찾을 수 없습니다."),
3838
TERMS_NOT_FOUND(HttpStatus.NOT_FOUND, 404, "요청한 종류의 약관을 찾을 수 없습니다."),
3939

40+
GOOGLE_USER_NOT_FOUND(NOT_FOUND,404,"구글 유저를 찾을 수 없습니다."),
41+
4042
HASH_MISMATCH(HttpStatus.BAD_REQUEST, 400, "인증 해시값이 일치하지 않습니다.")
4143

4244

0 commit comments

Comments
 (0)