Skip to content

Commit f8e0e23

Browse files
committed
fix: 프로필 없을때 리디렉션 처리
1 parent 358cbff commit f8e0e23

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

src/main/java/com/example/log4u/domain/user/controller/UserController.java

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -85,11 +85,11 @@ public ResponseEntity<String> loginAsDevTest(
8585
public ResponseEntity<UserProfileResponseDto> getMyProfile(
8686
@AuthenticationPrincipal CustomOAuth2User customOAuth2User
8787
) {
88-
// if (customOAuth2User.getRole().equals("ROLE_GUEST")) {
89-
// return ResponseEntity.status(HttpStatus.FOUND)
90-
// .location(URI.create(UrlConstants.PROFILE_CREATE_URL))
91-
// .build();
92-
// }
88+
if (customOAuth2User.getRole().equals("ROLE_GUEST")) {
89+
return ResponseEntity.status(HttpStatus.FOUND)
90+
.location(URI.create(UrlConstants.PROFILE_CREATE_URL))
91+
.build();
92+
}
9393

9494
UserProfileResponseDto userProfileResponseDto =
9595
userService.getMyProfile(customOAuth2User.getUserId());

0 commit comments

Comments
 (0)