From a2ce69aee1605a13d1b15b89f10be76c7a0da21d Mon Sep 17 00:00:00 2001 From: Dan Stillman Date: Mon, 27 Apr 2009 01:45:15 +0000 Subject: [PATCH] Fix error when a linked file appears twice in an export (e.g., in two subcollections) --- chrome/content/zotero/xpcom/translate.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/chrome/content/zotero/xpcom/translate.js b/chrome/content/zotero/xpcom/translate.js index bd7982d329..80c03ce277 100644 --- a/chrome/content/zotero/xpcom/translate.js +++ b/chrome/content/zotero/xpcom/translate.js @@ -2066,9 +2066,9 @@ Zotero.Translate.prototype._exportGetAttachment = function(attachment) { createInstance(Components.interfaces.nsILocalFile); directory.initWithFile(this._exportFileDirectory); directory.append(attachmentArray.itemID); - directory.create(Components.interfaces.nsIFile.DIRECTORY_TYPE, 0700); // copy file try { + directory.create(Components.interfaces.nsIFile.DIRECTORY_TYPE, 0700); file.copyTo(directory, attachmentArray.filename); } catch(e) { attachmentArray.path = undefined;