commit f5fb1fa806856c608bd2c33e8e6b6ec6f2e0206a
parent 574e6197a2a4da0d7e79b5d22bd3a5e6ac60e7e1
Author: Simon Kornblith <simon@simonster.com>
Date: Sun, 21 Dec 2008 18:16:31 +0000
don't download snapshots when snapshot is given as a document object and automaticSnapshots preference is false
Diffstat:
1 file changed, 6 insertions(+), 4 deletions(-)
diff --git a/chrome/content/zotero/xpcom/translate.js b/chrome/content/zotero/xpcom/translate.js
@@ -1410,10 +1410,12 @@ Zotero.Translate.prototype._itemDone = function(item, attachedTo) {
// if snapshot is not explicitly set to false, retrieve snapshot
if(attachment.document) {
- try {
- Zotero.Attachments.importFromDocument(attachment.document, myID, attachment.title);
- } catch(e) {
- Zotero.debug("Translate: Error attaching document", 2);
+ if(automaticSnapshots) {
+ try {
+ Zotero.Attachments.importFromDocument(attachment.document, myID, attachment.title);
+ } catch(e) {
+ Zotero.debug("Translate: Error attaching document", 2);
+ }
}
// Save attachment if snapshot pref enabled or not HTML
// (in which case downloadAssociatedFiles applies)