Fix "Export PDFs…" stopping if attachment file isn't found
This commit is contained in:
parent
540a174dab
commit
98c1a6ca1b
1 changed files with 4 additions and 0 deletions
|
@ -188,6 +188,10 @@ class PDFWorker {
|
|||
});
|
||||
}
|
||||
let attachmentPath = await attachment.getFilePathAsync();
|
||||
if (!attachmentPath) {
|
||||
Zotero.warn("Not exporting missing file " + attachment.getFilePath());
|
||||
return 0;
|
||||
}
|
||||
let buf = await IOUtils.read(attachmentPath);
|
||||
buf = new Uint8Array(buf).buffer;
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue