From eaa32235c549c36aab94696305ebd22fda3ebf21 Mon Sep 17 00:00:00 2001 From: A1300399510 Date: Mon, 25 Nov 2024 18:36:10 +0800 Subject: [PATCH] no message --- js/common.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/js/common.js b/js/common.js index da4b393..332e44f 100644 --- a/js/common.js +++ b/js/common.js @@ -2,7 +2,7 @@ const projectBaseURL = "https://project.gter.net" if (["localhost", "127.0.0.1"].includes(location.hostname)) { axios.defaults.headers = { - "Authorization": "97d1c7b2fe6dec05aaf52c0f3b9130e8", + Authorization: "97d1c7b2fe6dec05aaf52c0f3b9130e8", } } @@ -127,6 +127,8 @@ function getBaseData() { const currentTime = new Date().getTime() const timeDiff = currentTime - parseInt(storedTime) + console.log(storedTime && storedData && timeDiff <= 5 * 60 * 1000) + if (storedTime && storedData && timeDiff <= 5 * 60 * 1000) { // 在5分钟内,使用本地存储的数据 const basicData = JSON.parse(storedData)