From 01f2594108b07f318eae03534393df38b1b49471 Mon Sep 17 00:00:00 2001 From: Curt Tudor Date: Wed, 2 Oct 2024 14:52:03 -0600 Subject: [PATCH] feat: ignore 'pagehide' events that contain '/#/' in the URL (e.g. Jellyfin) (#359) --- src/runtime.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/runtime.js b/src/runtime.js index c295d25..f54f768 100644 --- a/src/runtime.js +++ b/src/runtime.js @@ -1670,7 +1670,7 @@ if (isUndefined(window.zitiBrowzerRuntime)) { window.addEventListener(terminationEvent, (e) => { // some web apps - if (!window.location.href.includes('#!')) { + if (!window.location.href.includes('#!') && !window.location.href.includes('/#/')) { setTimeout(function() { window.zitiBrowzerRuntime.logger.trace(`ZitiBrowzerRuntime page-terminationEvent setting window.location to: ${window.zitiBrowzerRuntime.zitiConfig.browzer.bootstrapper.target.path}`); window.location = window.zitiBrowzerRuntime.zitiConfig.browzer.bootstrapper.target.path;