fix(update): fast direct HTTP check & force cache bypass on check click (v1.3.7)
This commit is contained in:
1 parent
7ccb2189e7
commit
54fe591355
5 files changed
+37
-8
No files matched your search
@@ -5745,11 +5745,17 @@ async function checkSystemUpdate(notify = false) {
|
||||
return;
|
||||
} catch (_) {}
|
||||
}
|
||||
} else {
|
||||
localStorage.removeItem(STORAGE_KEY_TIME);
|
||||
localStorage.removeItem(STORAGE_KEY_DATA);
|
||||
}
|
||||
|
||||
let origBtnHtml = null;
|
||||
if (btnCheck) {
|
||||
btnCheck.disabled = true;
|
||||
btnCheck.classList.add('opacity-50');
|
||||
origBtnHtml = btnCheck.innerHTML;
|
||||
btnCheck.innerHTML = `<svg class="animate-spin w-4 h-4 text-cyan-400" fill="none" viewBox="0 0 24 24"><circle class="opacity-25" cx="12" cy="12" r="10" stroke="currentColor" stroke-width="4"></circle><path class="opacity-75" fill="currentColor" d="M4 12a8 8 0 018-8v8H4z"></path></svg><span>Vérification en cours...</span>`;
|
||||
}
|
||||
|
||||
try {
|
||||
@@ -5777,6 +5783,7 @@ async function checkSystemUpdate(notify = false) {
|
||||
if (btnCheck) {
|
||||
btnCheck.disabled = false;
|
||||
btnCheck.classList.remove('opacity-50');
|
||||
if (origBtnHtml) btnCheck.innerHTML = origBtnHtml;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user