mirror of
https://github.com/gorhill/uMatrix.git
synced 2024-09-29 08:41:11 +13:00
Firefox: fix tab closing issue (pop-up blocking)
This commit is contained in:
parent
f482164601
commit
6250109a78
1 changed files with 6 additions and 2 deletions
|
@ -127,7 +127,9 @@ const contentObserver = {
|
||||||
context = context.contentWindow || context;
|
context = context.contentWindow || context;
|
||||||
|
|
||||||
try {
|
try {
|
||||||
openerURL = context.opener.location.href;
|
if ( context !== context.opener ) {
|
||||||
|
openerURL = context.opener.location.href;
|
||||||
|
}
|
||||||
} catch (ex) {}
|
} catch (ex) {}
|
||||||
|
|
||||||
let isPopup = location.spec === 'about:blank' && openerURL;
|
let isPopup = location.spec === 'about:blank' && openerURL;
|
||||||
|
@ -139,7 +141,9 @@ const contentObserver = {
|
||||||
context = context.contentWindow || context;
|
context = context.contentWindow || context;
|
||||||
|
|
||||||
try {
|
try {
|
||||||
openerURL = context.opener.location.href;
|
if ( context !== context.opener ) {
|
||||||
|
openerURL = context.opener.location.href;
|
||||||
|
}
|
||||||
} catch (ex) {}
|
} catch (ex) {}
|
||||||
} else {
|
} else {
|
||||||
context = (context.ownerDocument || context).defaultView;
|
context = (context.ownerDocument || context).defaultView;
|
||||||
|
|
Loading…
Reference in a new issue