Skip to content

Commit b5cb626

Browse files
author
huishanyi
committed
fix: 更换判断条件
1 parent d6d70a4 commit b5cb626

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/axios/service.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ axiosInstance.interceptors.request.use((res: InternalAxiosRequestConfig) => {
1818
const controller = new AbortController()
1919
const url = res.url || ''
2020
res.signal = controller.signal
21-
abortControllerMap.set(import.meta.env.VITE_USE_MOCK ? url.replace('/mock', '') : url, controller)
21+
abortControllerMap.set(import.meta.env.VITE_USE_MOCK === 'true' ? url.replace('/mock', '') : url, controller)
2222
return res
2323
})
2424

0 commit comments

Comments
 (0)