Fix The Daily Beast (proper)

master
magnolia1234 2021-08-17 18:36:07 +02:00
parent 125da7daf5
commit 84b1f75a74
6 changed files with 74 additions and 66 deletions

View File

@ -1,6 +1,6 @@
# Bypass Paywalls Clean for Chrome
* [Installation instructions](#installation-instructions)
* [Installation](#installation)
* [Update](#update)
* [List of supported websites](#list-of-supported-websites)
* [Sites with limited number of free articles](#sites-with-limited-number-of-free-articles)
@ -11,7 +11,7 @@
* [Changelog-releases](#changelog-releases)
* [License](#license)
### Installation instructions
### Installation
Due to [Google internal policy](https://developer.chrome.com/webstore/program_policies), the extension is not available on the Chrome Web Store.
The following instructions are needed to install third-party extensions in [Chromium](https://en.wikipedia.org/wiki/Chromium_(web_browser))-based desktop browsers.
In extension developer mode you can always install BPC by `Load unpacked` (latest master, but no automatic updates) or by crx-file (latest release & automatic updates, but possible 'whitelisting' of extension is needed).
@ -51,7 +51,9 @@ Windows Registry Editor Version 5.00
#### Android
1. Install [Kiwi Browser](https://play.google.com/store/apps/details?id=com.kiwibrowser.browser&hl=nl) or [Yandex Browser](https://play.google.com/store/apps/details?id=com.yandex.browser&hl=en) from the Google PlayStore.
2. For Kiwi Browser load the CRX-file in releases (auto-updating, no whitelist needed, opt-in for custom sites not working (use kiwi-custom crx; updates to latest regular version)) or use latest master zip-file (no automatic updates, for custom sites use manifest.json from custom folder).
2. For Kiwi Browser you have two options:
* load the CRX-file in releases (auto-updating, no whitelist needed, opt-in for custom sites not working (use kiwi-custom crx; updates to latest regular version))
* install latest master zip-file (no automatic updates, for custom sites use manifest.json from custom folder).
3. For Yandex Browser follow Chrome instructions above (load unpacked; step 6: pick manifest.json instead of the folder). If it fails try a few times or use Total Commander (as file manager). You can use a Git client like MGit to clone (and update) this repository on your mobile device.\
For custom sites copy manifest.json from custom folder to the main extension folder (optional permissions are lost on reload).
@ -61,9 +63,8 @@ Visit the [Firefox repository](https://gitlab.com/magnolia1234/bypass-paywalls-f
#### Notes
* This extension works best alongside the adblocker [uBlock Origin](https://chrome.google.com/webstore/detail/ublock-origin/cjpalhdlnbpafiamejdnhcphjbkeiagm?hl=en).
* On Yandex Android use [uBlock Origin development build](https://chrome.google.com/webstore/detail/ublock-origin-dev-build/cgbcahbpdhpcegmbfconppldiemgcoii).
* If you live in the EU, also consider installing the extension [I don't care about cookies](https://chrome.google.com/webstore/detail/i-dont-care-about-cookies/fihnjjcciajhdojfnbdddfaoknhalnja) in order to remove cookie warnings (or add filter [Easylist Cookies](https://easylist-downloads.adblockplus.org/easylist-cookie.txt) | [I don't care about cookies custom filter](https://www.i-dont-care-about-cookies.eu/abp) to uBlock Origin). Some sites need to set a consent-cookie for (social) media.
* Do not delete extension's folder from your computer/smartphone or Bypass Paywalls Clean (in developer mode) will disappear at restart.
* Every time you open Chrome it may warn you about running extensions in developer mode, just close the popup to keep the extension enabled.
* In Chrome/Opera/Brave to disable the developer mode extensions popup use the extensions toolbar menu (by default enabled in Chrome 87+ or (if available) enable (experimental) chrome flag: chrome://flags/#extensions-toolbar-menu)
* You will be logged out for most of the sites you have checked.
### Update
@ -185,8 +186,8 @@ NHST Media Group sites like
[New York Magazine](https://www.nymag.com) (+ [Curbed](https://www.curbed.com/), [Grub Street](https://www.grubstreet.com), [The Cut](https://www.thecut.com) & [Vulture](https://www.vulture.com)) -
[Newsday](https://www.newsday.com) -
[Palo Alto Online](https://www.paloaltoonline.com) -
[Pittsburgh Post Gazette](https://post-gazette.com) -
[San Diego Union Tribune](https://sandiegouniontribune.com) -
[Pittsburgh Post Gazette](https://www.post-gazette.com) -
[San Diego Union Tribune](https://www.sandiegouniontribune.com) -
[San Francisco Chronicle](https://www.sfchronicle.com) -
[Star Tribune](https://www.startribune.com) -
[The Atlanta Journal-Constitution](https://www.ajc.com) -
@ -198,7 +199,7 @@ NHST Media Group sites like
[USA Today](https://www.usatoday.com)\
Grouped in options:\
*Gannett Group (local USA Today)* sites like (opt-in to custom sites)
*Gannett Group (local USA Today)* sites like (opt-in to custom sites)\
[Detroit Free Press](https://www.freep.com) -
[Milwaukee Journal Sentinel](https://www.jsonline.com) -
[The Indianapolis Star](https://www.indystar.com) -
@ -208,7 +209,7 @@ Grouped in options:\
[Crain's Cleveland Business](https://www.crainscleveland.com) -
[Crain's Detroit Business](https://www.crainsdetroit.com) -
[Crain's New York Business](https://www.crainsnewyork.com)\
*McClatchy Group* sites like (opt-in to custom sites for unlisted)
*McClatchy Group* sites like (opt-in to custom sites for unlisted)\
[Belleville News-Democrat](https://www.bnd.com) -
[Fort Worth Star-Telegram](https://www.star-telegram.com) -
[Lexington Herald-Leader](https://www.kentucky.com) -
@ -221,14 +222,14 @@ Grouped in options:\
[The State](https://www.thestate.com) -
[The Wichita Eagle](https://www.kansas.com) -
[Tri-City Herald](https://www.tri-cityherald.com)\
*MediaNews Group* sites like (opt-in to custom sites for unlisted/local sites):
*MediaNews Group* sites like (opt-in to custom sites for unlisted/local sites)\
[East Bay Times](https://www.eastbaytimes.com) -
[Orange County Register](https://www.ocregister.com) -
[St. Paul Pioneer Press](https://www.twincities.com) -
[The Denver Post](https://www.denverpost.com) -
[The Mercury News](https://www.mercurynews.com) -
[The Press-Enterprise](https://www.pe.com)\
*Tribune Publishing Company* sites like
*Tribune Publishing Company* sites like\
[Baltimore Sun](https://www.baltimoresun.com) -
[Chicago Tribune](https://www.chicagotribune.com) -
[Daily Press](https://www.dailypress.com) -
@ -281,12 +282,11 @@ Grouped in options:\
##### Finland
Grouped in options:\
Sanoma Media Finland sites like
*Sanoma Media Finland* sites like (opt-in to custom sites for unlisted/regional sites)\
[Aamulehti](https://www.aamulehti.fi) -
[Helsingin Sanomat](https://www.hs.fi)
* opt-in to custom sites for unlisted/regional sites
Alma Talent sites like
*Alma Talent* sites like\
[Arvopaperi](https://www.arvopaperi.fi) -
[Iltalehti (Firefox-only)](https://www.iltalehti.fi/) -
[Kauppalehti](https://www.kauppalehti.fi) -
@ -322,9 +322,10 @@ Alma Talent sites like
[Science & Vie](https://www.science-et-vie.com) -
[Sciences et Avenir](https://www.sciencesetavenir.fr) -
[Sud Ouest](https://www.sudouest.fr) -
[Valeurs Actuelles](https://www.valeursactuelles.com)\
[Valeurs Actuelles](https://www.valeursactuelles.com)
Grouped in options:\
Groupe EBRA sites like
*Groupe EBRA* sites like\
[Dernières Nouvelles d'Alsace](https://www.dna.fr) -
[L'Alsace](https://www.lalsace.fr) -
[L'Est Républicain](https://www.estrepublicain.fr) -
@ -334,7 +335,7 @@ Groupe EBRA sites like
[Le Progrès](https://www.leprogres.fr) -
[Le Républicain Lorrain](https://www.republicain-lorrain.fr) -
[Vosges Matin](https://www.vosgesmatin.fr)\
Groupe La Dépêche sites like
*Groupe La Dépêche* sites like\
[Centre Presse](https://www.centrepresseaveyron.fr) -
[L'Indépendant](https://www.lindependant.fr) -
[La Dépêche du Midi](https://www.ladepeche.fr) -
@ -342,7 +343,7 @@ Groupe La Dépêche sites like
[Le Petit Bleu d'Agen](https://www.petitbleu.fr) -
[Midi Libre](https://www.midilibre.fr) -
[Midi Olympique](https://www.midi-olympique.fr)
Groupe Rossel sites (grouped in options) like
*Groupe Rossel* sites like\
[L'Aisne nouvelle](https://www.aisnenouvelle.fr) -
[L'Ardennais](https://www.lardennais.fr) -
[L'Est-Éclair](https://www.lest-eclair.fr) -
@ -377,9 +378,10 @@ Groupe Rossel sites (grouped in options) like
[Schleswig-Holsteinischer Zeitungsverlag](https://www.shz.de) -
[Schweriner Volkszeitung](https://www.svz.de) -
[Süddeutsche Zeitung](https://www.sueddeutsche.de) -
[WirtschaftsWoche](https://www.wiwo.de)\
[WirtschaftsWoche](https://www.wiwo.de)
Grouped in options:\
Funke Mediengruppe sites like
*Funke Mediengruppe* sites like\
[Berliner Morgenpost](https://www.morgenpost.de) -
[Braunschweiger Zeitung](https://www.braunschweiger-zeitung.de) -
[Hamburger Abendblatt](https://www.abendblatt.de) -
@ -390,7 +392,7 @@ Funke Mediengruppe sites like
[Westdeutsche Allgemeine Zeitung](https://www.waz.de) -
[Westfalenpost](https://www.wp.de) -
[Westfälische Rundschau](https://www.wr.de)\
Madsack Mediengruppe sites like (opt-in to custom sites for unlisted)
*Madsack Mediengruppe* sites like (opt-in to custom sites for unlisted)\
[Hannoversche Allgemeine Zeitung](https://www.haz.de) -
[Kieler Nachrichten](https://www.kn-online.de) -
[Leipziger Volkszeitung](https://www.lvz.de) -
@ -410,7 +412,8 @@ Madsack Mediengruppe sites like (opt-in to custom sites for unlisted)
[La Repubblica](https://www.repubblica.it) -
[La Stampa](https://www.lastampa.it) -
[Le Scienze](https://www.lescienze.it) -
[LimesOnline (it/en)](https://www.limesonline.com)\
[LimesOnline (it/en)](https://www.limesonline.com)
Grouped in options:\
[Il Messaggero](https://www.ilmessaggero.it) and regional sites like
[Corriere Adriatico](https://www.corriereadriatico.it) -
@ -438,7 +441,8 @@ Grouped in options:\
[Parool](https://www.parool.nl) -
[Telegraaf](https://www.telegraaf.nl) -
[Trouw](https://www.trouw.nl) -
[Volkskrant](https://www.volkskrant.nl)\
[Volkskrant](https://www.volkskrant.nl)
Grouped in options:\
[Algemeen Dagblad](https://www.ad.nl) and regional ADR sites like
[BN DeStem](https://www.bndestem.nl) -
@ -448,7 +452,7 @@ Grouped in options:\
[PZC](https://www.pzc.nl) -
[Stentor](https://www.destentor.nl) -
[Tubantia](https://tubantia.nl)\
Mediahuis Nederland Regional sites like
*Mediahuis Nederland Regional* sites like\
[Noordhollands Dagblad](https://www.noordhollandsdagblad.nl) -
[Haarlems Dagblad](https://www.haarlemsdagblad.nl) -
[Leidsch Dagblad](https://www.leidschdagblad.nl) -
@ -479,9 +483,10 @@ Mediahuis Nederland Regional sites like
[La Vanguardia](https://www.lavanguardia.com) -
[Levante-EMV](https://www.levante-emv.com) -
[Marca](https://www.marca.com) -
[Política Exterior](https://www.politicaexterior.com)\
[Política Exterior](https://www.politicaexterior.com)
Grouped in options:\
Grupo Vocento (ABC) regional sites like
*Grupo Vocento* (ABC regional) sites like\
[Diario Vasco](https://www.diariovasco.com) -
[El Comercio](https://www.elcomercio.es) -
[El Correo](https://www.elcorreo.com) -
@ -512,7 +517,9 @@ Grupo Vocento (ABC) regional sites like
#### Australia/New Zealand
[Brisbane Times](https://www.brisbanetimes.com.au) -
[Eureka Report](https://www.eurekareport.com.au) -
[Griffith Review](https://www.griffithreview.com) -
[Intelligent Investor](https://www.intelligentinvestor.com.au) -
[New Zealand Herald](https://www.nzherald.co.nz) -
[The Age](https://www.theage.com.au) -
[The Australian Financial Review](https://www.afr.com) -
@ -522,7 +529,8 @@ Grupo Vocento (ABC) regional sites like
[The West Australian (+ regional)](https://thewest.com.au) -
[WAtoday](https://www.watoday.com.au)
##### > News Corp Australia (grouped in options)
Grouped in options:\
*News Corp Australia* site like\
[Cairns Post](https://www.cairnspost.com.au) -
[Geelong Advertiser](https://www.geelongadvertiser.com.au) -
[Gold Coast Bulletin](https://www.goldcoastbulletin.com.au) -
@ -535,14 +543,8 @@ Grupo Vocento (ABC) regional sites like
[The Daily Telegraph](https://www.dailytelegraph.com.au) -
[The Mercury Tasmania](https://www.themercury.com.au) -
[The Weekly Times](https://www.weeklytimesnow.com.au) -
[Townsville Bulletin](https://www.townsvillebulletin.com.au)
##### > Financial
[Eureka Report](https://www.eurekareport.com.au) -
[Intelligent Investor](https://www.intelligentinvestor.com.au)
##### > Australian Community Media (daily, grouped in options)
[Townsville Bulletin](https://www.townsvillebulletin.com.au)\
*Australian Community Media (daily)* sites like (add to custom sites for unlisted & block general paywall-script Piano)\
[Bendigo Advertiser](https://www.bendigoadvertiser.com.au) -
[Central Western Daily](https://www.centralwesterndaily.com.au) -
[Daily Liberal](https://www.dailyliberal.com.au) -
@ -557,10 +559,8 @@ Grupo Vocento (ABC) regional sites like
[The Northern Daily Leader](https://www.northerndailyleader.com.au) -
[The Port Macquarie News](https://www.portnews.com.au) -
[The Standard](https://www.standard.net.au) -
[Western Advocate](https://www.westernadvocate.com.au)
* add to custom sites for unlisted & block general paywall-script Piano
##### > Australian Provincial Newspapers (all, grouped in options)
[Western Advocate](https://www.westernadvocate.com.au)\
*Australian Provincial Newspapers* site like (opt-in to custom sites for unlisted)\
[Bundaberg News Mail](https://www.news-mail.com.au) -
[Fraser Coast Chronicle](https://www.frasercoastchronicle.com.au) -
[Gladstone Observer](https://www.gladstoneobserver.com.au) -
@ -571,7 +571,6 @@ Grupo Vocento (ABC) regional sites like
[The Gympie Times](https://www.gympietimes.com.au) -
[The Queensland Times](https://www.qt.com.au) -
[Warwick Daily News](https://www.warwickdailynews.com.au)
* opt-in to custom sites for unlisted
#### East Asia
[Asia Times](https://asiatimes.com) -
@ -647,9 +646,9 @@ For user with the limited permissions BPC-version this will only work for suppor
If removing the cookies works you can also add the site as a custom site.
### New site requests
You can submit a request for a new website [here](https://gitlab.com/magnolia1234/bypass-paywalls-chrome-clean/-/issues).
You can [submit a request for a new website](https://gitlab.com/magnolia1234/bypass-paywalls-chrome-clean/-/issues).
Please read the following instructions and share your results for a quicker process.
Remember to check the [previous requests](https://gitlab.com/magnolia1234/bypass-paywalls-chrome-clean/-/issues) before asking for a new website.
Remember to check the [previous requests](https://gitlab.com/magnolia1234/bypass-paywalls-chrome-clean/-/issues?scope=all&state=all) before asking for a new website.
1. Visit an article on the site you want to bypass the paywall for and copy the article title.
2. Open up a new incognito window (Ctrl+Shift+N) and paste the article title into Google.
3. Click on the same article from the Google search results page. Or you can:
@ -659,7 +658,7 @@ Remember to check the [previous requests](https://gitlab.com/magnolia1234/bypass
### Add custom site
Add your own custom site (also for testing).
Check 'Options'-link in popup-menu and go to custom sites.
\* by default BPC has limited permissions, but you can opt-in to enable custom sites (and also clear cookies/block general paywall-scripts for non-listed sites). You can also just request permissions for the custom sites you added.
\* by default BPC has limited permissions, but you can opt-in to enable custom sites (and also clear cookies/block general paywall-scripts for non-listed sites). You can also just request permissions for the custom sites you added yourself.
Make sure the (new) site is checked under Options (or check on/off-button).
By default sites' cookies/local storage are removed after page loads (to bypass article limit).
@ -674,8 +673,10 @@ You can also exclude a specific domain which is grouped in options.
* Add usefull custom filter [Fanboy's Enhanced Tracking List](https://www.fanboy.co.nz/enhancedstats.txt)
* If a site doesn't work, try turning off uBlock and refreshing.
* Make sure the (new) site is checked under Options.
* You will be logged out for most of the sites you have checked.
* Make sure you're running the latest version of Bypass Paywalls Clean.
* If none of these work, you can submit an issue [here](https://gitlab.com/magnolia1234/bypass-paywalls-chrome-clean/-/issues).
* If none of these work, you can [submit an issue](https://gitlab.com/magnolia1234/bypass-paywalls-chrome-clean/-/issues).
* If you live in the EU, also consider installing the extension [I don't care about cookies](https://chrome.google.com/webstore/detail/i-dont-care-about-cookies/fihnjjcciajhdojfnbdddfaoknhalnja) in order to remove cookie warnings (or add filter [Easylist Cookies](https://easylist-downloads.adblockplus.org/easylist-cookie.txt) | [I don't care about cookies custom filter](https://www.i-dont-care-about-cookies.eu/abp) to uBlock Origin). Some sites need to set a consent-cookie for (social) media.
### Changelog-releases
* Visit the [changelog page](https://gitlab.com/magnolia1234/bypass-paywalls-chrome-clean/-/blob/master/changelog.txt).

View File

@ -363,6 +363,7 @@ var blockedRegexes = {
'nytimes.com': /(meter-svc\.nytimes\.com\/meter\.js|mwcm\.nyt\.com\/.+\.js)/,
'observador.pt': /\.tinypass\.com\//,
'parismatch.com': /\.poool\.fr\//,
'post-gazette.com': /(cdn\.cxense\.com\/|\.tinypass\.com\/)/,
'qz.com': /\.tinypass\.com\//,
'reuters.com': /\.reuters\.com\/(arc\/subs\/p\.min|pf\/resources\/dist\/reuters\/js\/index)\.js/,
'rollingstone.com': /cdn\.cxense\.com\//,

View File

@ -3,6 +3,7 @@ Changelog Bypass Paywalls Clean - Chrome
Post-release
Add MediaNews Group (local USA)
Fix The Daily Beast (proper)
* v2.3.3.0 (2021-08-15)
Add Live Law (India)

View File

@ -17,8 +17,8 @@ var it_repubblica_domains = ['gelocal.it', 'ilsecoloxix.it', 'lanuovasardegna.it
var it_quotidiano_domains = ['ilgiorno.it', 'ilrestodelcarlino.it', 'iltelegrafolivorno.it', 'lanazione.it', 'quotidiano.net'];
var nl_mediahuis_region_domains = ['gooieneemlander.nl', 'haarlemsdagblad.nl', 'ijmuidercourant.nl', 'leidschdagblad.nl', 'noordhollandsdagblad.nl'];
var no_nhst_media_domains = ['intrafish.com', 'rechargenews.com', 'tradewindsnews.com', 'upstreamonline.com'];
var usa_crainsbiz_domains = ['chicagobusiness.com', 'crainscleveland.com', 'crainsdetroit.com', 'crainsnewyork.com'];
var timesofindia_domains = ['timesofindia.com', 'timesofindia.indiatimes.com'];
var usa_crainsbiz_domains = ['chicagobusiness.com', 'crainscleveland.com', 'crainsdetroit.com', 'crainsnewyork.com'];
var usa_mcc_domains = ['bnd.com', 'charlotteobserver.com', 'fresnobee.com', 'kansas.com', 'kansascity.com', 'kentucky.com', 'miamiherald.com', 'newsobserver.com', 'sacbee.com', 'star-telegram.com', 'thestate.com', 'tri-cityherald.com'];
var usa_mng_domains = ['denverpost.com', 'eastbaytimes.com', 'mercurynews.com', 'ocregister.com', 'pe.com', 'twincities.com'];
var usa_tribune_domains = ['baltimoresun.com', 'chicagotribune.com', 'courant.com', 'dailypress.com', 'mcall.com', 'nydailynews.com', 'orlandosentinel.com', 'pilotonline.com', 'sun-sentinel.com'];
@ -382,11 +382,11 @@ else if (matchDomain('faz.net')) {
.then(response => {
if (response.ok) {
response.text().then(html => {
var parser = new DOMParser();
var doc = parser.parseFromString(html, 'text/html');
let parser = new DOMParser();
let doc = parser.parseFromString(html, 'text/html');
let json = doc.querySelector('script[id="schemaOrgJson"]');
if (json) {
var json_text = json.text.replace(/(\r|\n)/g, '');
let json_text = json.text.replace(/(\r|\n)/g, '');
let split1 = json_text.split('"ArticleBody": "');
let split2 = split1[1].split('","author":');
if (split2[0].includes('"'))
@ -753,7 +753,7 @@ else if (matchDomain('politicaexterior.com')) {
let article = document.querySelector('div.entry-content-text');
let json = document.querySelector('script[type="application/ld+json"]:not([class]');
if (json) {
var json_text = JSON.parse(json.text).description.replace(/ /g, '');
let json_text = JSON.parse(json.text).description.replace(/ /g, '');
let article_new = document.createElement('div');
article_new.setAttribute('class', 'entry-content-text');
article_new.innerText = '\r\n' + json_text;
@ -1903,7 +1903,7 @@ else if (matchDomain('economist.com')) {
}
}, 600); // Delay (in milliseconds)
let p_articles = document.querySelectorAll('p.article__body-text');
var href;
let href;
for (let p_article of p_articles) {
let e_anchors = document.querySelectorAll('a');
href = '';
@ -1951,7 +1951,7 @@ else if (matchDomain('foreignaffairs.com')) {
elem.classList.add('loaded');
let hidden_images = document.querySelectorAll('img[src^="data:image/"]');
for (let hidden_image of hidden_images) {
var data_src = hidden_image.getAttribute('data-src');
let data_src = hidden_image.getAttribute('data-src');
if (data_src) {
hidden_image.setAttribute('src', data_src);
hidden_image.removeAttribute('class');
@ -2096,8 +2096,8 @@ else if (matchDomain('inkl.com')) {
if (dive_deeper_summary_bodies) {
for (let summary_body of dive_deeper_summary_bodies) {
if (!summary_body.querySelector('a')) {
var ng_click = summary_body.getAttribute('ng-click').replace("showArticle('", '').replace("')", '');
var weblink = document.createElement('a');
let ng_click = summary_body.getAttribute('ng-click').replace("showArticle('", '').replace("')", '');
let weblink = document.createElement('a');
weblink.text = 'open';
weblink.href = 'https://www.inkl.com/news/' + ng_click;
summary_body.appendChild(weblink);
@ -2340,8 +2340,10 @@ else if (matchDomain('republic.ru')) {
else if (matchDomain('sandiegouniontribune.com')) {
let metering_bottompanel = document.querySelector('metering-bottompanel');
removeDOMElement(metering_bottompanel);
window.setTimeout(function () {
let metering_bottompanel = document.querySelector('metering-bottompanel');
removeDOMElement(metering_bottompanel);
}, 500); // Delay (in milliseconds)
}
else if (matchDomain('scmp.com') && window.location.href.includes('/amp.')) {
@ -2523,7 +2525,10 @@ else if (matchDomain('thedailybeast.com')) {
removeDOMElement(paywall);
let json_script = document.querySelector('script[displayName="initialState"]');
if (json_script) {
let json_text = json_script.innerText.includes('"sections":') ? json_script.innerText.split('"sections":')[1].split('},"')[0] : '';
let json_split = json_script.innerText.includes('"sections":') ? json_script.innerText.split('"sections":') : [];
let json_text;
if (json_split.length > 1)
json_text = json_split[json_split.length - 1].split('},"')[0];
if (json_text) {
let pars = json_text.split('"').filter(function (value) {
return (value.split('[').length < 3 && value.split(']').length < 3);
@ -2911,7 +2916,7 @@ function addDivBpcDone() {
}
function matchDomain(domains, hostname) {
var matched_domain = false;
let matched_domain = false;
if (!hostname)
hostname = window.location.hostname;
if (typeof domains === 'string')
@ -2989,7 +2994,7 @@ function cookieExists(name) {
}
function setCookie(name, value, domain, path, days) {
var max_age = days * 24 * 60 * 60;
let max_age = days * 24 * 60 * 60;
document.cookie = name + "=" + (value || "") + "; domain=" + domain + "; path=" + path + "; max-age=" + max_age;
}
@ -3013,9 +3018,9 @@ function genHexString(len) {
function makeRandomNumber(len) {
let result = '';
var characters = '123456789';
var charactersLength = characters.length;
for (var i = 0; i < len; i++)
let characters = '123456789';
let charactersLength = characters.length;
for (let i = 0; i < len; i++)
result += characters.charAt(Math.floor(Math.random() * charactersLength));
return result;
}
@ -3028,13 +3033,13 @@ function pageContains(selector, text) {
}
function parseHtmlEntities(encodedString) {
var translate_re = /&(nbsp|amp|quot|lt|gt|deg|hellip|laquo|raquo|ldquo|rdquo|lsquo|rsquo|mdash);/g;
var translate = {"nbsp": " ", "amp": "&", "quot": "\"", "lt": "<", "gt": ">", "deg": "°", "hellip": "…",
let translate_re = /&(nbsp|amp|quot|lt|gt|deg|hellip|laquo|raquo|ldquo|rdquo|lsquo|rsquo|mdash);/g;
let translate = {"nbsp": " ", "amp": "&", "quot": "\"", "lt": "<", "gt": ">", "deg": "°", "hellip": "…",
"laquo": "«", "raquo": "»", "ldquo": "“", "rdquo": "”", "lsquo": "", "rsquo": "", "mdash": "—"};
return encodedString.replace(translate_re, function (match, entity) {
return translate[entity];
}).replace(/&#(\d+);/gi, function (match, numStr) {
var num = parseInt(numStr, 10);
let num = parseInt(numStr, 10);
return String.fromCharCode(num);
});
}

View File

@ -38,5 +38,5 @@
"webRequestBlocking",
"<all_urls>"
],
"version": "2.3.3.1"
"version": "2.3.3.2"
}

View File

@ -539,5 +539,5 @@
"*://*.wallkit.net/*",
"*://*.wsj.net/*"
],
"version": "2.3.3.1"
"version": "2.3.3.2"
}