1
0
Fork 0
mirror of https://github.com/gorhill/uMatrix.git synced 2024-06-26 18:10:39 +12:00

Firefox: fix tab closing issue (pop-up blocking)

This commit is contained in:
Deathamns 2015-01-15 15:58:14 +01:00 committed by gorhill
parent f482164601
commit 6250109a78

View file

@ -127,7 +127,9 @@ const contentObserver = {
context = context.contentWindow || context;
try {
openerURL = context.opener.location.href;
if ( context !== context.opener ) {
openerURL = context.opener.location.href;
}
} catch (ex) {}
let isPopup = location.spec === 'about:blank' && openerURL;
@ -139,7 +141,9 @@ const contentObserver = {
context = context.contentWindow || context;
try {
openerURL = context.opener.location.href;
if ( context !== context.opener ) {
openerURL = context.opener.location.href;
}
} catch (ex) {}
} else {
context = (context.ownerDocument || context).defaultView;