Fix cross-site document saving

This commit is contained in:
Simon Kornblith 2012-03-05 23:47:27 -05:00
parent 36cfad3933
commit 2facd4fcbd

View file

@ -310,6 +310,10 @@ Zotero.Translate.ItemSaver.prototype = {
|| downloadAssociatedFiles; || downloadAssociatedFiles;
if(!shouldAttach) return; if(!shouldAttach) return;
if(attachment.document && "__wrappedDOMObject" in attachment.document) {
attachment.document = attachment.document.__wrappedDOMObject;
}
if(attachment.snapshot === false || !this._saveFiles) { if(attachment.snapshot === false || !this._saveFiles) {
// if snapshot is explicitly set to false, attach as link // if snapshot is explicitly set to false, attach as link
if(attachment.document) { if(attachment.document) {