We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 4244bc0 commit 9af1ab8Copy full SHA for 9af1ab8
1 file changed
apps/ticket/src/lib/axios/clientAxios.ts
@@ -65,19 +65,25 @@ clientAxios.interceptors.response.use(
65
}
66
67
68
+ console.log(error.response?.data);
69
+
70
// 로그인이 필요한 요청이거나, 리프레시 토큰 모두 만료시 로그인 페이지로 이동
71
if (isAxiosErrorResponse(error.response?.data)) {
72
const { code } = error.response?.data ?? {};
73
74
// 엑세스 토큰 없음
75
if (code === ERROR_CODE.NO_ACCESS_TOKEN || code === ERROR_CODE.REFRESH_TOKEN_EXPIRED) {
76
redirectToLoginOnce();
77
78
+ return;
79
80
81
if (code === ERROR_CODE.LOGIN_REQUIRED) {
82
// 인증 페이지에서는 로그인 페이지로 이동하지 않음
83
if (window.location.pathname !== "/auth") {
84
85
86
87
88
89
0 commit comments