From 823ce3964a48ad22504c5394f7b7fb44a14b52e4 Mon Sep 17 00:00:00 2001 From: veronees Date: Tue, 26 Nov 2024 15:19:44 +0900 Subject: [PATCH] =?UTF-8?q?fix:=20=EB=A6=AC=EB=8B=A4=EC=9D=B4=EB=A0=89?= =?UTF-8?q?=ED=8A=B8=20url=20=EC=88=98=EC=A0=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../jaebichuri/auth/controller/AuthController.java | 12 ++++++------ submodule | 2 +- 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/src/main/java/com/api/jaebichuri/auth/controller/AuthController.java b/src/main/java/com/api/jaebichuri/auth/controller/AuthController.java index 8ce1ae2..ec32d3b 100644 --- a/src/main/java/com/api/jaebichuri/auth/controller/AuthController.java +++ b/src/main/java/com/api/jaebichuri/auth/controller/AuthController.java @@ -16,7 +16,6 @@ import java.util.Map; import lombok.RequiredArgsConstructor; import lombok.extern.slf4j.Slf4j; -import org.springframework.beans.factory.annotation.Value; import org.springframework.http.ResponseEntity; import org.springframework.security.core.annotation.AuthenticationPrincipal; import org.springframework.web.bind.annotation.GetMapping; @@ -34,8 +33,7 @@ public class AuthController { private final AuthService authService; private final MemberService memberService; - @Value("${redirect.url}") - private String redirectBaseUrl; + private final static String LOGIN_SUCCESS_REDIRECT_URL = "https://ecomarket-cuk.netlify.app"; @Operation( summary = "카카오 로그인 페이지로 리다이렉트 API", @@ -59,9 +57,10 @@ public void callBack( Map memberInfo = authService.getMemberInfo(code); LoginSuccessDto loginSuccessDto = memberService.login(memberInfo); - String redirectUrl = redirectBaseUrl + "?isFirstLogin=" + loginSuccessDto.getIsFirstLogin() - + "&accessToken=" + loginSuccessDto.getTokenResponseDto().getAccessToken() - + "&refreshToken=" + loginSuccessDto.getTokenResponseDto().getRefreshToken(); + String redirectUrl = + LOGIN_SUCCESS_REDIRECT_URL + "?isFirstLogin=" + loginSuccessDto.getIsFirstLogin() + + "&accessToken=" + loginSuccessDto.getTokenResponseDto().getAccessToken() + + "&refreshToken=" + loginSuccessDto.getTokenResponseDto().getRefreshToken(); response.sendRedirect(redirectUrl); } @@ -102,6 +101,7 @@ public ResponseEntity> logout(@AuthenticationPrincipal Membe private final JwtUtil jwtUtil; + @Deprecated @GetMapping("/test/login") public ResponseEntity> getTestAccessToken(@RequestParam String clientId) { diff --git a/submodule b/submodule index e8cdb7f..61360a4 160000 --- a/submodule +++ b/submodule @@ -1 +1 @@ -Subproject commit e8cdb7fe33437b8d780dfd44a520cd9c373d7b18 +Subproject commit 61360a4e8e7fade8009a3f5d0fc40a2b97ae4192