fix: 锁屏重启判断

This commit is contained in:
TsMask
2024-01-18 11:42:34 +08:00
parent 13738d5b4e
commit 4d7d31f784
2 changed files with 5 additions and 9 deletions

View File

@@ -27,7 +27,7 @@ const useLockedStore = defineStore('locked', {
this.fnLock('none');
window.location.reload();
}
} catch (e) {
} catch (error) {
// 延迟5秒
setTimeout(() => {
this.relaodWait();
@@ -35,7 +35,7 @@ const useLockedStore = defineStore('locked', {
}
},
// 设置锁定
async fnLock(type: 'none' | 'lock' | 'reload') {
async fnLock(type: 'none' | 'lock' | 'reload' | string) {
this.type = type;
localSet(CACHE_LOCAL_LOCK, type);
if (type === 'reload') {