From b3a0ea73af3a9414fbbfb136176369e9d1edcfb2 Mon Sep 17 00:00:00 2001 From: h_mo <596417202@qq.com> Date: Wed, 28 Aug 2024 22:53:26 +0800 Subject: [PATCH] =?UTF-8?q?fix(http):=20=E4=BF=AE=E5=A4=8D=20http=20?= =?UTF-8?q?=E9=85=8D=E7=BD=AE=E9=94=99=E8=AF=AF?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/utils/http/index.ts | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/utils/http/index.ts b/src/utils/http/index.ts index 7ea9b1d..2ccb370 100644 --- a/src/utils/http/index.ts +++ b/src/utils/http/index.ts @@ -21,7 +21,6 @@ const ContentType = { */ const alovaInstance = createAlova({ baseURL: BASE_URL, - localCache: null, // 设置为null即可全局关闭全部请求缓存 ...AdapterUniapp({ /* #ifndef APP-PLUS */ mockRequest: isUseMock() ? mockAdapter : undefined, // APP 平台无法使用mock @@ -62,7 +61,7 @@ const alovaInstance = createAlova({ throw new Error(`请求错误[${code}]:${message}`); } // 处理http状态错误 - handleHttpStatus(statusCode, message || ''); + handleHttpStatus(statusCode, errMsg || ''); throw new Error(`HTTP请求错误[${statusCode}]:${errMsg}`); },