Reader: Use url (was baseURI) for all reader types

This commit is contained in:
Abe Jellinek 2023-09-15 12:33:53 -04:00
parent 1b23838d37
commit 667f940a6c
2 changed files with 2 additions and 8 deletions

View file

@ -531,14 +531,8 @@ class ReaderInstance {
if (fileSize > ARRAYBUFFER_MAX_LENGTH) {
throw new Error(`The file "${path}" is too large`);
}
let buf;
if (this._type !== 'pdf') {
buf = await OS.File.read(path, {});
}
let baseURI = `zotero://attachment/${Zotero.API.getLibraryPrefix(item.libraryID)}/items/${item.key}/`;
return {
buf,
baseURI
url: `zotero://attachment/${Zotero.API.getLibraryPrefix(item.libraryID)}/items/${item.key}/`
};
}

2
reader

@ -1 +1 @@
Subproject commit 81863a19d7f62685e6c3ab8ce893647b9dfb7351
Subproject commit c13fd93c26ea118f48f2a4c0495e21131b4e3180