From d294c9449ddb14e769a4aba5c5b323663b09574e Mon Sep 17 00:00:00 2001 From: Deon George Date: Mon, 16 Jun 2025 20:04:05 +1000 Subject: [PATCH] Fix page expired 419 started showing a page expired message, instead of refreshing the session and loading the clicked item on the tree --- public/js/custom.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/public/js/custom.js b/public/js/custom.js index 87795db4..1f652ade 100644 --- a/public/js/custom.js +++ b/public/js/custom.js @@ -37,11 +37,11 @@ function getNode(item) { $('.main-content').empty().append(e.responseText); break; case 409: // Not in root - location.replace('/#'+item); - break; case 419: // Session Expired location.replace('/#'+item); - location.reload(); + // When the session expires, and we are in the tree, we need to force a reload + if (location.pathname === '/') + location.reload(); break; case 500: case 555: // Missing Method