From f2f653945e1c13b7e7d22fa287d5af998cb76656 Mon Sep 17 00:00:00 2001 From: gorhill Date: Wed, 2 Dec 2015 01:13:56 -0500 Subject: [PATCH] can throw when trying to access `associatedWindow` --- platform/firefox/vapi-background.js | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/platform/firefox/vapi-background.js b/platform/firefox/vapi-background.js index 9d52f91b9..4be5e56ab 100644 --- a/platform/firefox/vapi-background.js +++ b/platform/firefox/vapi-background.js @@ -1936,7 +1936,10 @@ var httpObserver = { if ( lc.topFrameElement ) { return tabWatcher.tabIdFromTarget(lc.topFrameElement); } - var win = lc.associatedWindow; + var win; + try { + win = lc.associatedWindow; + } catch (ex) { } if ( !win ) { return vAPI.noTabId; } if ( win.top ) { win = win.top;