From 7c585e4e2d3bd1f6bbc77ac541fe8412ac47ebe5 Mon Sep 17 00:00:00 2001
From: zym2525 <540361168@qq.com>
Date: 星期四, 20 二月 2025 21:01:46 +0800
Subject: [PATCH] fix: config

---
 apps/taro/src/utils/request/index.ts |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)

diff --git a/apps/taro/src/utils/request/index.ts b/apps/taro/src/utils/request/index.ts
index 5842e65..356eca8 100644
--- a/apps/taro/src/utils/request/index.ts
+++ b/apps/taro/src/utils/request/index.ts
@@ -3,6 +3,7 @@
 import qs from 'qs';
 import Taro from '@tarojs/taro';
 import { getToken, Message } from '@/utils';
+import { isWeb } from '@/utils/env';
 import { tokenIsExpired, SensitiveManage } from '@life-payment/utils';
 import { useUserStoreWithOut } from '@/stores/modules/user';
 
@@ -76,7 +77,7 @@
 }
 
 const AxiosOptions: AxiosRequestConfig = {
-  baseURL: process.env.BASE_URL,
+  baseURL: isWeb ? process.env.BASE_URL_H5 : process.env.BASE_URL,
   timeout: 10 * 1000,
   headers: {
     Accept: 'application/json, text/plain, */*',

--
Gitblit v1.9.1