Add $document to adblock filter parsing

This commit is contained in:
SukkaW 2022-12-07 17:46:19 +08:00
parent 9774611ea9
commit 12bb3bf83a

View File

@ -194,12 +194,16 @@ async function processFilterRules (filterRulesUrl, fallbackUrls) {
lineEndsWithCaret
|| lineEndsWithCaretVerticalBar
|| line.endsWith('^$all')
|| line.endsWith('^$doc')
|| line.endsWith('^$document')
)
) {
const _domain = line
.replaceAll('||', '')
.replaceAll('^|', '')
.replaceAll('^$all', '')
.replaceAll('^$document', '')
.replaceAll('^$doc', '')
.replaceAll('^', '')
.trim();