check host instead of the whole href for occurence of wikipedia.org

This commit is contained in:
Kotuklion 2021-07-12 18:48:52 +02:00
parent 058ca7b6e0
commit 010d19aff9
1 changed files with 1 additions and 1 deletions

View File

@ -601,7 +601,7 @@ browser.webRequest.onBeforeRequest.addListener(
redirect = {
redirectUrl: redirectGoogleTranslate(url, initiator),
};
} else if (url.href.match(wikipediaRegex)) {
} else if (url.host.match(wikipediaRegex)) {
redirect = {
redirectUrl: redirectWikipedia(url, initiator),
};