|
|
@ -1228,7 +1228,7 @@ if (matchUrlDomain(change_headers, details.url) && (['main_frame', 'sub_frame',
|
|
|
|
}
|
|
|
|
}
|
|
|
|
if ((!['font', 'stylesheet'].includes(details.type) || matchUrlDomain(cs_limit_except, currentTabUrl)) && !csDone) {
|
|
|
|
if ((!['font', 'stylesheet'].includes(details.type) || matchUrlDomain(cs_limit_except, currentTabUrl)) && !csDone) {
|
|
|
|
let lib_file = 'lib/empty.js';
|
|
|
|
let lib_file = 'lib/empty.js';
|
|
|
|
if (matchUrlDomain(['cicero.de', 'economictimes.com', 'gva.be', 'lesechos.fr', 'newleftreview.org', 'newyorker.com', 'nzherald.co.nz', 'prospectmagazine.co.uk', 'sudouest.fr', 'techinasia.com', 'tradewindsnews.com', 'valor.globo.com', 'washingtonpost.com'].concat(nl_mediahuis_region_domains), currentTabUrl))
|
|
|
|
if (matchUrlDomain(['bloomberg.com', 'cicero.de', 'economictimes.com', 'gva.be', 'lesechos.fr', 'newleftreview.org', 'newyorker.com', 'nzherald.co.nz', 'prospectmagazine.co.uk', 'sudouest.fr', 'techinasia.com', 'tradewindsnews.com', 'valor.globo.com', 'washingtonpost.com'].concat(nl_mediahuis_region_domains), currentTabUrl))
|
|
|
|
lib_file = 'lib/purify.min.js';
|
|
|
|
lib_file = 'lib/purify.min.js';
|
|
|
|
ext_api.tabs.executeScript(tabId, {
|
|
|
|
ext_api.tabs.executeScript(tabId, {
|
|
|
|
file: lib_file,
|
|
|
|
file: lib_file,
|
|
|
@ -1440,7 +1440,7 @@ function remove_cookies_fn(domainVar, exclusions = false) {
|
|
|
|
// remove cookies after page load
|
|
|
|
// remove cookies after page load
|
|
|
|
ext_api.webRequest.onCompleted.addListener(function (details) {
|
|
|
|
ext_api.webRequest.onCompleted.addListener(function (details) {
|
|
|
|
let domainVar = matchUrlDomain(remove_cookies, details.url);
|
|
|
|
let domainVar = matchUrlDomain(remove_cookies, details.url);
|
|
|
|
if (domainVar && ['main_frame', 'xmlhttprequest', 'other'].includes(details.type) && enabledSites.includes(domainVar))
|
|
|
|
if (domainVar && ['main_frame', 'sub_frame', 'xmlhttprequest', 'other'].includes(details.type) && enabledSites.includes(domainVar))
|
|
|
|
remove_cookies_fn(domainVar, true);
|
|
|
|
remove_cookies_fn(domainVar, true);
|
|
|
|
}, {
|
|
|
|
}, {
|
|
|
|
urls: ["<all_urls>"]
|
|
|
|
urls: ["<all_urls>"]
|
|
|
|