attachment content rendering

This commit is contained in:
zadam
2023-05-21 18:14:17 +02:00
parent e20fac19ba
commit 579ed7e194
12 changed files with 115 additions and 44 deletions

View File

@@ -10,13 +10,13 @@ function getAttachmentBlob(req) {
function getAttachments(req) {
const note = becca.getNoteOrThrow(req.params.noteId);
return note.getAttachments();
return note.getAttachments({includeContentLength: true});
}
function getAttachment(req) {
const {attachmentId} = req.params;
return becca.getAttachmentOrThrow(attachmentId);
return becca.getAttachmentOrThrow(attachmentId, {includeContentLength: true});
}
function saveAttachment(req) {