File tree Expand file tree Collapse file tree 1 file changed +8
-3
lines changed
Expand file tree Collapse file tree 1 file changed +8
-3
lines changed Original file line number Diff line number Diff line change @@ -2,8 +2,8 @@ import useAuthStore from "@/stores/useAuthStore";
22import axios from "axios" ;
33
44const apiClient = axios . create ( {
5- // baseURL: import.meta.env.DEV ? "/api" : import.meta.env.VITE_BASE_URL,
6- baseURL : import . meta. env . VITE_BASE_URL ,
5+ baseURL : import . meta. env . DEV ? "/api" : import . meta. env . VITE_BASE_URL ,
6+ // baseURL: import.meta.env.VITE_BASE_URL,
77 timeout : 10000 ,
88 withCredentials : true ,
99 headers : {
@@ -20,7 +20,12 @@ apiClient.interceptors.response.use(
2020 const originalRequest = error . config ;
2121
2222 // refresh를 시도하지 않아야 하는 URL 목록
23- const skipRefreshUrls = [ "/auth/login" , "/auth/register" , "/auth/logout" ] ;
23+ const skipRefreshUrls = [
24+ "/auth/login" ,
25+ "/auth/register" ,
26+ "/auth/logout" ,
27+ "/auth/refresh" ,
28+ ] ;
2429 const shouldSkipRefresh = skipRefreshUrls . some ( ( url ) =>
2530 originalRequest . url ?. includes ( url )
2631 ) ;
You can’t perform that action at this time.
0 commit comments