mirror of
https://github.com/kremalicious/metamask-extension.git
synced 2024-11-25 03:20:23 +01:00
Fix injection blocklist regex (#20584)
This commit is contained in:
parent
9514b47a7e
commit
b9097de9b3
@ -81,7 +81,7 @@ function blockedDomainCheck() {
|
|||||||
const currentUrl = window.location.href;
|
const currentUrl = window.location.href;
|
||||||
let currentRegex;
|
let currentRegex;
|
||||||
for (let i = 0; i < blockedDomains.length; i++) {
|
for (let i = 0; i < blockedDomains.length; i++) {
|
||||||
const blockedDomain = blockedDomains[i].replace('.', '\\.');
|
const blockedDomain = blockedDomains[i].replaceAll('.', '\\.');
|
||||||
currentRegex = new RegExp(
|
currentRegex = new RegExp(
|
||||||
`(?:https?:\\/\\/)(?:(?!${blockedDomain}).)*$`,
|
`(?:https?:\\/\\/)(?:(?!${blockedDomain}).)*$`,
|
||||||
'u',
|
'u',
|
||||||
|
Loading…
Reference in New Issue
Block a user