mirror of
https://gitlab.com/magnolia1234/bypass-paywalls-firefox-clean.git
synced 2024-09-20 07:33:40 +02:00
WashingtonPost.com GDPR bypass with timeout fix
I've added a timeout to the GDPR bypass code, now it works properly in Firefox too.
This commit is contained in:
parent
5cfeebd791
commit
163e953439
1 changed files with 16 additions and 1 deletions
|
@ -50,4 +50,19 @@ if (window.location.href.indexOf("bizjournals.com") !== -1) {
|
||||||
document.querySelector('.close-btn').click();
|
document.querySelector('.close-btn').click();
|
||||||
}, 2000);
|
}, 2000);
|
||||||
}
|
}
|
||||||
|
} else if (window.location.href.indexOf("washingtonpost.com") !== -1) {
|
||||||
|
if (location.href.includes('/gdpr-consent/')) {
|
||||||
|
document.querySelector('.gdpr-consent-container .continue-btn.button.free').click();
|
||||||
|
|
||||||
|
setTimeout(function (){
|
||||||
|
|
||||||
|
const gdprcheckbox = document.querySelector('.gdpr-consent-container .consent-page:not(.hide) #agree');
|
||||||
|
if (gdprcheckbox) {
|
||||||
|
gdprcheckbox.checked = true;
|
||||||
|
gdprcheckbox.dispatchEvent(new Event('change'));
|
||||||
|
|
||||||
|
document.querySelector('.gdpr-consent-container .consent-page:not(.hide) .continue-btn.button.accept-consent').click();
|
||||||
|
}
|
||||||
|
}, 300); // Delay (in milliseconds)
|
||||||
|
}
|
||||||
}
|
}
|
Loading…
Reference in a new issue