From 630249d22a45907264fbaec717463b1c6ad06896 Mon Sep 17 00:00:00 2001 From: GyDi Date: Thu, 16 Mar 2023 17:03:12 +0800 Subject: [PATCH] fix: adjust swr option --- src/pages/_layout.tsx | 2 +- src/services/api.ts | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/src/pages/_layout.tsx b/src/pages/_layout.tsx index 1027ecc..77639bc 100644 --- a/src/pages/_layout.tsx +++ b/src/pages/_layout.tsx @@ -76,7 +76,7 @@ const Layout = () => { }, [language]); return ( - + { axiosIns = axios.create({ baseURL: `http://${server}`, headers: secret ? { Authorization: `Bearer ${secret}` } : {}, + timeout: 15000, }); axiosIns.interceptors.response.use((r) => r.data); return axiosIns;