Work-around for potential issues with legacy prefs.

This commit is contained in:
hackademix 2019-03-27 23:48:27 +01:00
parent 5327505fba
commit c806c6bbff
1 changed files with 5 additions and 3 deletions

View File

@ -50,9 +50,11 @@ XSS.Exceptions = (() => {
}
// destination or @source matching legacy regexp
if (this.legacyExceptions.test(unescapedDest) &&
!this.isBadException(destObj.hostname) ||
this.legacyExceptions.test("@" + unescape(srcUrl))) {
if (this.legacyExceptions &&
(this.legacyExceptions.test(unescapedDest) &&
!this.isBadException(destObj.hostname) ||
this.legacyExceptions.test("@" + unescape(srcUrl))
)) {
logEx("Legacy exception", this.legacyExceptions);
return true;
}