From f341bb1ae036338c020362fc4266155add4993e3 Mon Sep 17 00:00:00 2001 From: Dan Stillman Date: Sun, 4 Aug 2013 23:30:28 -0400 Subject: [PATCH] Fix error exporting linked HTML file https://forums.zotero.org/discussion/29392/#Item_14 --- chrome/content/zotero/xpcom/translation/translate_item.js | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/chrome/content/zotero/xpcom/translation/translate_item.js b/chrome/content/zotero/xpcom/translation/translate_item.js index afab5df4da..6778820dfb 100644 --- a/chrome/content/zotero/xpcom/translation/translate_item.js +++ b/chrome/content/zotero/xpcom/translation/translate_item.js @@ -822,9 +822,10 @@ Zotero.Translate.ItemGetter.prototype = { var directory = targetFile.parent; - // The only attachments that can have multiple supporting files are of mime type - // text/html (specified in Attachments.getNumFiles()) - if(attachment.attachmentMIMEType == "text/html" + // The only attachments that can have multiple supporting files are imported + // attachments of mime type text/html (specified in Attachments.getNumFiles()) + if(attachment.attachmentMIMEType == "text/html" + && linkMode != Zotero.Attachments.LINK_MODE_LINKED_FILE && Zotero.Attachments.getNumFiles(attachment) > 1) { // Attachment is a snapshot with supporting files. Check if any of the // supporting files would cause a name conflict, and build a list of transfers