diff --git a/background.js b/background.js index 5089a24..1faa7d7 100644 --- a/background.js +++ b/background.js @@ -190,6 +190,7 @@ var use_google_bot_default = [ 'republic.ru', 'ruhrnachrichten.de', 'seekingalpha.com', + 'statista.com', 'stratfor.com', 'thetimes.co.uk', 'usinenouvelle.com', @@ -259,7 +260,7 @@ var blockedRegexes = { 'freiepresse.de': /cdn\.ampproject\.org\/v\d\/amp-(access|ad|consent)-.+\.js/, 'fresnobee.com': /cdn\.ampproject\.org\/v\d\/amp-subscriptions-.+\.js/, 'ftm.nl': /.+\.ftm\.nl\/js\/routing\?/, - 'gelocal.it': /cdn\.ampproject\.org\/v\d\/amp-(access|ad)-.+\.js/, + 'gelocal.it': /(\.repstatic.\it\/minify\/sites\/gelocal\/.+\/config\.cache(_\d)?\.php|cdn\.ampproject\.org\/v\d\/amp-(access|ad)-.+\.js)/, 'gestion.pe': /gestion\.pe\/pf\/dist\/template\/gestion-noticia.+\.js/, 'globes.co.il': /\.tinypass\.com\/.+/, 'globo.com': /\.tinypass\.com\/.+/, @@ -269,7 +270,7 @@ var blockedRegexes = { 'hbr.org': /\.tinypass\.com\/.+/, 'historyextra.com': /.+\.evolok\.net\/.+\/authorize\/.+/, 'ilrestodelcarlino.it': /\.tinypass\.com\/.+/, - 'ilsecoloxix.it': /\.repstatic\.it\/minify\/sites\/gelocal\/.+\/config\.cache\.php\?name=ilsecoloxix_pw_js/, + 'ilsecoloxix.it': /(\.repstatic\.it\/minify\/sites\/gelocal\/.+\/config\.cache\.php\?name=ilsecoloxix_pw_js|cdn\.ampproject\.org\/v\d\/amp-(access|ad)-.+\.js)/, 'independent.ie': /(cdn\.flip-pay\.com\/clients\/inm\/flip-pay\.js|cdn\.ampproject\.org\/v\d\/amp-(access|ad|consent)-.+\.js)/, 'inquirer.com': /\.tinypass\.com\/.+/, 'irishtimes.com': /cdn\.ampproject\.org\/v\d\/amp-(access|ad)-.+\.js/, @@ -899,7 +900,7 @@ ext_api.webRequest.onBeforeSendHeaders.addListener(function(details) { let usa_mw_site = (matchUrlDomain('wsj.net', details.url) && matchUrlDomain('marketwatch.com', header_referer) && isSiteEnabled({url: header_referer})); let bpc_amp_site = (matchUrlDomain('cdn.ampproject.org', details.url) && isSiteEnabled({url: header_referer}) && - matchUrlDomain(['barrons.com', 'belfasttelegraph.co.uk', 'cicero.de', 'cmjornal.pt', 'elmundo.es', 'elpais.com', 'elperiodico.com', 'expansion.com', 'freiepresse.de', 'fresnobee.com', 'gelocal.it', 'independent.ie', 'irishtimes.com', 'la-croix.com', 'lne.es', 'marketwatch.com', 'nationalreview.com', 'sacbee.com', 'seekingalpha.com', 'sueddeutsche.de', 'svz.de', 'telegraph.co.uk'].concat(au_nine_domains, de_madsack_domains, de_rp_medien_domains, es_grupo_vocento_domains, fr_groupe_ebra_domains, fr_groupe_la_depeche_domains), header_referer)); + matchUrlDomain(['barrons.com', 'belfasttelegraph.co.uk', 'cicero.de', 'cmjornal.pt', 'elmundo.es', 'elpais.com', 'elperiodico.com', 'expansion.com', 'freiepresse.de', 'fresnobee.com', 'gelocal.it', 'ilsecoloxix.it', 'independent.ie', 'irishtimes.com', 'la-croix.com', 'lne.es', 'marketwatch.com', 'nationalreview.com', 'sacbee.com', 'seekingalpha.com', 'sueddeutsche.de', 'svz.de', 'telegraph.co.uk'].concat(au_nine_domains, de_madsack_domains, de_rp_medien_domains, es_grupo_vocento_domains, fr_groupe_ebra_domains, fr_groupe_la_depeche_domains), header_referer)); if (!isSiteEnabled(details) && !inkl_site && !au_nc_amp_site && !au_apn_site && !au_swm_site && !cl_elmerc_site && !medium_custom_domain && !uk_nlr_site && !usa_discmag_site && !usa_mw_site && !bpc_amp_site) { return; diff --git a/changelog.txt b/changelog.txt index 9089dd5..8b4e8e2 100644 --- a/changelog.txt +++ b/changelog.txt @@ -4,7 +4,9 @@ Changelog Bypass Paywalls Clean - Firefox Post-release Add Time Magazine Fix-update Cors Anywhere (link to allow access) +Fix-update Il Secolo XIX (amp) Fix-update Medium custom domains (meter) +Fix-update Statista (premium) * v2.0.7.0 (2021-02-07) Add Diario de Ibiza/Mallorca, Faro de Vigo & La Provincia (Spain) diff --git a/contentScript.js b/contentScript.js index 856b467..717d0ef 100644 --- a/contentScript.js +++ b/contentScript.js @@ -1514,24 +1514,16 @@ else if (matchDomain("kurier.at")) { plus_content.classList.remove('plusContent'); } -else if (matchDomain('gelocal.it')) { +else if (matchDomain(['gelocal.it', 'ilsecoloxix.it'])) { let premium = document.querySelector('.paywall-adagio'); let url = window.location.href; if (!url.includes('/amp/')) { - if (premium) { - removeDOMElement(premium); - if (url.includes('?')) - window.location.href = url.replace('?', '/amp/?'); - else - window.location.href = url + '/amp/'; - } + removeDOMElement(premium); } else { - let paywall = document.querySelector('div[amp-access="showContent"]'); - if (paywall) - paywall.removeAttribute('amp-access-hide'); + document.querySelector('div[amp-access="showContent"]')?.removeAttribute('amp-access-hide'); ; + let amp_ads = document.querySelectorAll('amp-ad'); + removeDOMElement(...amp_ads); } - let amp_ads = document.querySelectorAll('amp-ad'); - removeDOMElement(...amp_ads); } else if (matchDomain("gva.be")) { diff --git a/manifest.json b/manifest.json index b5e8af0..805a1ef 100644 --- a/manifest.json +++ b/manifest.json @@ -461,5 +461,5 @@ "*://*.userzoom.com/*", "*://*.wsj.net/*" ], - "version": "2.0.7.2" + "version": "2.0.7.3" } \ No newline at end of file