mirror of
https://github.com/zadam/trilium.git
synced 2026-01-02 12:44:25 +01:00
chore(server): fix type error
This commit is contained in:
parent
f3cfa84d1d
commit
d96528dae4
@ -168,10 +168,10 @@ function renderNoteContentInternal(note: SNote | BNote, renderArgs: RenderArgs)
|
||||
// When rendering static share, non-protected JavaScript notes should be rendered as-is.
|
||||
if (renderArgs.isStatic && note.mime.startsWith("application/javascript")) {
|
||||
if (note.isProtected) {
|
||||
return `console.log("Protected note cannot be exported.");`
|
||||
};
|
||||
return `console.log("Protected note cannot be exported.");`;
|
||||
}
|
||||
|
||||
return note.getContent();
|
||||
return note.getContent() ?? "";
|
||||
}
|
||||
|
||||
const { header, content, isEmpty } = getContent(note);
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user