mirror of
https://github.com/zadam/trilium.git
synced 2025-11-07 05:46:10 +01:00
fix unloading protected session after the timeout, fixes #571
This commit is contained in:
@@ -43,6 +43,7 @@ async function setupProtectedSession(password) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
protectedSessionHolder.setProtectedSessionId(response.protectedSessionId);
|
protectedSessionHolder.setProtectedSessionId(response.protectedSessionId);
|
||||||
|
protectedSessionHolder.touchProtectedSession();
|
||||||
|
|
||||||
await treeService.reload();
|
await treeService.reload();
|
||||||
|
|
||||||
|
|||||||
@@ -37,6 +37,8 @@ function isProtectedSessionAvailable() {
|
|||||||
|
|
||||||
function touchProtectedSession() {
|
function touchProtectedSession() {
|
||||||
if (isProtectedSessionAvailable()) {
|
if (isProtectedSessionAvailable()) {
|
||||||
|
lastProtectedSessionOperationDate = new Date();
|
||||||
|
|
||||||
setProtectedSessionId(utils.getCookie(PROTECTED_SESSION_ID_KEY));
|
setProtectedSessionId(utils.getCookie(PROTECTED_SESSION_ID_KEY));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user