commit 4535bb5315238ae8f8f74360e3cb8dbf15fd989e
parent 1ad5b9fd639bada21a4eecc4e01cdfb152bf68f5
Author: Simon Kornblith <simon@simonster.com>
Date: Tue, 9 Oct 2012 18:29:21 -0400
Update for https://bugzilla.mozilla.org/show_bug.cgi?id=794602
Diffstat:
1 file changed, 5 insertions(+), 1 deletion(-)
diff --git a/chrome/content/zotero/xpcom/attachments.js b/chrome/content/zotero/xpcom/attachments.js
@@ -351,7 +351,11 @@ Zotero.Attachments = new function(){
var nsIURL = Components.classes["@mozilla.org/network/standard-url;1"]
.createInstance(Components.interfaces.nsIURL);
nsIURL.spec = url;
- wbp.saveURI(nsIURL, null, null, null, null, file);
+ try {
+ wbp.saveURI(nsIURL, null, null, null, null, file);
+ } catch(e if e.name === "NS_ERROR_XPC_NOT_ENOUGH_ARGS") {
+ wbp.saveURI(nsIURL, null, null, null, null, file, null);
+ }
return attachmentItem;
}