From 4a2f0d16ac315b76c8dbdc3bd103d64e3d14396c Mon Sep 17 00:00:00 2001 From: Soulter <905617992@qq.com> Date: Mon, 16 Sep 2024 07:58:45 -0400 Subject: [PATCH] perf: pass authorization header to backend --- frontend/src/main.js | 6 +----- frontend/src/pages/world.vue | 2 +- frontend/src/utils/axios-wrapper.js | 4 ++++ 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/frontend/src/main.js b/frontend/src/main.js index cd2e0d8..bd4e038 100644 --- a/frontend/src/main.js +++ b/frontend/src/main.js @@ -39,11 +39,7 @@ const bus = mitt() // app.config.globalProperties.$axios = { ...axiosInstance } // }) -const axiosInstance = axios.create({ - withCredentials: true, - baseURL: store.state.base_url, -}) -app.config.globalProperties.$axios = { ...axiosInstance } +app.config.globalProperties.$axios = axios app.config.globalProperties.$bus = bus diff --git a/frontend/src/pages/world.vue b/frontend/src/pages/world.vue index 480bc7a..e96fbc6 100644 --- a/frontend/src/pages/world.vue +++ b/frontend/src/pages/world.vue @@ -68,7 +68,7 @@