From b5760d7f45d203b6dab993e9a2ca6ba2a2d278c7 Mon Sep 17 00:00:00 2001 From: Simon Kornblith Date: Mon, 16 Dec 2013 21:59:36 -0500 Subject: [PATCH] Don't try to detect a proxy on documents with no docShell/webNav This would previously have thrown an error. I'm not sure what these documents would be, but it's a safe bet that they're not loaded in a normal browser window. --- chrome/content/zotero/xpcom/proxy.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/chrome/content/zotero/xpcom/proxy.js b/chrome/content/zotero/xpcom/proxy.js index e279221a6..235db323e 100644 --- a/chrome/content/zotero/xpcom/proxy.js +++ b/chrome/content/zotero/xpcom/proxy.js @@ -147,7 +147,9 @@ Zotero.Proxies = new function() { try { webNav = channel.notificationCallbacks.QueryInterface(Components.interfaces.nsIWebNavigation); docShell = channel.notificationCallbacks.QueryInterface(Components.interfaces.nsIDocShell); - } catch(e) {} + } catch(e) { + return; + } if(!docShell.allowMetaRedirects) return;