Fix-update Spectator.co.uk (amp for premium)

master
magnolia1234 2020-05-27 07:41:27 +02:00
parent f78144f003
commit 8134734171
1 changed files with 9 additions and 0 deletions

View File

@ -655,6 +655,15 @@ else if (matchDomain('elmundo.es')) {
}
}
else if (matchDomain('spectator.co.uk')) {
let premium = document.querySelector('.HardPayWallContainer-module__overlay');
window.setTimeout(function () {
if (premium && window.location.href.includes('/www.spectator.co.uk/')) {
window.location.href = window.location.href + '/amp';
}
}, 500); // Delay (in milliseconds)
}
// General Functions
function removeDOMElement(...elements) {
for (let element of elements) {