diff options
author | ManeraKai <manerakai@protonmail.com> | 2024-05-20 14:34:18 +0300 |
---|---|---|
committer | ManeraKai <manerakai@protonmail.com> | 2024-05-20 14:34:18 +0300 |
commit | abcd566305d0ede82bf81c4809fd59ea7c67591c (patch) | |
tree | c2dda909ce789357056e6ccca2064666bdf30880 /src/pages | |
parent | Fixed timestamps being removed for invidious https://github.com/libredirect/b... (diff) | |
download | libredirect-abcd566305d0ede82bf81c4809fd59ea7c67591c.zip |
Removed ?si= from youtube frontends https://github.com/libredirect/browser_extension/issues/922
Diffstat (limited to 'src/pages')
-rw-r--r-- | src/pages/background/background.js | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/pages/background/background.js b/src/pages/background/background.js index 3df43b52..0754f8a5 100644 --- a/src/pages/background/background.js +++ b/src/pages/background/background.js @@ -32,6 +32,7 @@ let tabIdRedirects = {} browser.webRequest.onBeforeRequest.addListener( details => { const url = new URL(details.url) + const old_href = url.href if (new RegExp(/^chrome-extension:\/{2}.*\/instances\/.*.json$/).test(url.href) && details.type == "xmlhttprequest") return let initiator try { @@ -71,7 +72,7 @@ browser.webRequest.onBeforeRequest.addListener( if (tabIdRedirects[details.tabId] != false) tabIdRedirects[details.tabId] = false return null } - console.log("Redirecting", url.href, "=>", newUrl) + console.log("Redirecting", old_href, "=>", newUrl) return { redirectUrl: newUrl } } return null |