From 5d2b7e28a8f0cbe7b46b4ac2f73fce2b5d8ed4fd Mon Sep 17 00:00:00 2001 From: LingYuZhao Date: Fri, 12 Apr 2024 19:39:26 +0800 Subject: [PATCH] update --- web/js/indexMain.js | 2 +- web/js/main.js | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/web/js/indexMain.js b/web/js/indexMain.js index 7300340..59bbd92 100644 --- a/web/js/indexMain.js +++ b/web/js/indexMain.js @@ -8,7 +8,7 @@ document.getElementById("submitButton").addEventListener("click", function () { jokerBoxPopUp.show("请您输入信息哦!!! ") return; } - if (value === undefined) { + if (value === undefined || value.length === 0) { value = '0'; } document.cookie = `diskMirror_server_pass=${value}; path=/`; diff --git a/web/js/main.js b/web/js/main.js index 1925290..1e79eed 100644 --- a/web/js/main.js +++ b/web/js/main.js @@ -139,7 +139,6 @@ window.onload = function () { }, (e) => { progressBar.setProgressByValue(0, 'linear-gradient(to right, rgba(255, 255, 255, 0.5), #8c00ff)') - progressBar.setProgressByValue(124 << 10 << 10, 128 << 10 << 10, 'linear-gradient(to right, rgba(255, 255, 255, 0.5), #8c00ff)') if ('res' in e) { if (e['res'].endsWith("不可读!!!")) { // 这里代表用户是第一次使用 盘镜 所以可能没有目录 但并不代表是发生了错误!!! @@ -179,6 +178,8 @@ window.onload = function () { fsList.setPath(searchParams[searchParams.length - 1]); } return; + } else { + progressBar.setProgressByValue(124 << 10 << 10, 128 << 10 << 10, 'linear-gradient(to right, rgba(255, 255, 255, 0.5), #8c00ff)'); } console.error(e); new FS_List('fileName', [