From faca7f62852796e55e3d4d94dbab5ada8023c535 Mon Sep 17 00:00:00 2001 From: Davide Saurino Date: Fri, 25 Jan 2019 16:29:06 +0100 Subject: [PATCH] Fix repubblica.it after website update --- contentScript.js | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/contentScript.js b/contentScript.js index be6313c..6092282 100644 --- a/contentScript.js +++ b/contentScript.js @@ -35,9 +35,13 @@ if (window.location.href.indexOf("bizjournals.com") !== -1) { } if (location.href.includes("/ws/detail/")) { - const paywall = document.querySelector('.paywall[amp-access-hide]'); + const paywall = document.querySelector('.paywall[subscriptions-section="content"]'); if (paywall) { - paywall.removeAttribute('amp-access-hide'); + paywall.removeAttribute('subscriptions-section'); + const preview = document.querySelector('div[subscriptions-section="content-not-granted"]'); + if (preview) { + preview.remove(); + } } } }