has -> contains, parent -> parentElement

master
moshmage 2021-01-08 18:19:40 +00:00 committed by GitHub
parent 5f47a52141
commit 8acf4e4c6e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 2 additions and 2 deletions

View File

@ -77,11 +77,11 @@ const INJECTION = {
observador: {
url: /observador.pt/,
code: `
if (!document.body.classList.has(`premium-article`))
if (!document.body.classList.contains(`premium-article`))
return;
document.body.classList.remove(`premium-article`);
const paywall = document.querySelector(`.premium-paywall`);
paywall.parent.removeChild(paywall);
paywall.parentElement.removeChild(paywall);
document.querySelector(`.article-body-wrapper`).style.maxHeight = `inherit`
`
}