Skip to content

Build your personal knowledge base with Trilium Notes

Update utils.ts to fix backend bug that prevented library items from loading

CobriMediaJuliene64e51c0783f
diff --git a/src/services/utils.ts b/src/services/utils.ts
index 1d93d724cc..1c7a7e12ba 100644
--- a/src/services/utils.ts
+++ b/src/services/utils.ts
@@ -160,7 +160,7 @@ const STRING_MIME_TYPES = [
"image/svg+xml"
];
-function isStringNote(type: string | null, mime: string) {
+function isStringNote(type: string | undefined, mime: string) {
// render and book are string note in the sense that they are expected to contain empty string
return (type && ["text", "code", "relationMap", "search", "render", "book", "mermaid", "canvas"].includes(type))
|| mime.startsWith('text/')