mirror of
https://codeberg.org/LibRedirect/libredirect.git
synced 2025-02-09 08:38:40 +01:00
Fixed a bug in exceptions
This commit is contained in:
parent
587b16e107
commit
d488aff7b3
@ -49,8 +49,6 @@ browser.webRequest.onBeforeRequest.addListener(
|
||||
|
||||
var newUrl;
|
||||
|
||||
if (exceptionsHelper.isException(url, initiator)) newUrl = null;
|
||||
|
||||
if (!newUrl) newUrl = youtubeHelper.redirect(url, details, initiator)
|
||||
if (youtubeMusicHelper.isYoutubeMusic(url, initiator)) newUrl = youtubeMusicHelper.redirect(url, details.type)
|
||||
|
||||
@ -75,10 +73,12 @@ browser.webRequest.onBeforeRequest.addListener(
|
||||
if (wikipediaHelper.isWikipedia(url, initiator)) newUrl = wikipediaHelper.redirect(url);
|
||||
|
||||
if (youtubeHelper.isPipedorInvidious(newUrl ?? url, details.type)) newUrl = youtubeHelper.addUrlParams(newUrl ?? url);
|
||||
else console.log("isPipedorInvidiousisFalse");
|
||||
|
||||
if (exceptionsHelper.isException(url, initiator)) newUrl = null;
|
||||
|
||||
if (bybassTabs.includes(details.tabId)) newUrl = null;
|
||||
|
||||
|
||||
if (newUrl) {
|
||||
if (newUrl == 'CANCEL') {
|
||||
console.log(`Canceled ${url}`);
|
||||
|
Loading…
x
Reference in New Issue
Block a user