Disallow attachment.path in web/search translators
This commit is contained in:
parent
8be83cedec
commit
cf9ec26eb4
1 changed files with 7 additions and 0 deletions
|
@ -631,6 +631,13 @@ Zotero.Translate.Sandbox = {
|
|||
|
||||
for(var i=0; i<item.attachments.length; i++) {
|
||||
var attachment = item.attachments[i];
|
||||
|
||||
// Web translators are not allowed to use attachment.path
|
||||
if (attachment.path) {
|
||||
if (!attachment.url) attachment.url = attachment.path;
|
||||
delete attachment.path;
|
||||
}
|
||||
|
||||
if(attachment.url) {
|
||||
// Remap attachment (but not link) URLs
|
||||
attachment.url = translate.resolveURL(attachment.url, attachment.snapshot === false);
|
||||
|
|
Loading…
Reference in a new issue