Skip to content

Commit 0a12ef0

Browse files
committed
♻️ refactor: 리다이렉트 문자열 변수로 분리
1 parent af3b029 commit 0a12ef0

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

backend/src/main/java/io/f1/backend/domain/user/app/handler/OAuthSuccessHandler.java

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,9 +25,11 @@ public void onAuthenticationSuccess(
2525
response.setContentType("application/json;charset=UTF-8");
2626

2727
if (principal.getUserNickname() == null) {
28-
getRedirectStrategy().sendRedirect(request, response, "http://localhost:3000/signup");
28+
String SIGNUP_REDIRECT_URL = "http://localhost:3000/signup";
29+
getRedirectStrategy().sendRedirect(request, response, SIGNUP_REDIRECT_URL);
2930
} else {
30-
getRedirectStrategy().sendRedirect(request, response, "http://localhost:3000/room");
31+
String MAIN_REDIRECT_URL = "http://localhost:3000/room";
32+
getRedirectStrategy().sendRedirect(request, response, MAIN_REDIRECT_URL);
3133
}
3234
}
3335
}

0 commit comments

Comments
 (0)