Skip to content

A fully open source & end-to-end encrypted note taking alternative to Evernote.

fix: input.includes is not a function

thecodrr383bdb1c8fa6
diff --git a/packages/core/utils/html-parser.js b/packages/core/utils/html-parser.js
index 39762f76b..4e17f7908 100644
--- a/packages/core/utils/html-parser.js
+++ b/packages/core/utils/html-parser.js
@@ -19,6 +19,7 @@ export function getInnerText(element) {
}
function wrapIntoHTMLDocument(input) {
+ if (typeof input !== "string") return input;
if (input.includes("<body>")) return input;
return `<!doctype html><html lang="en"><head><title>Document Fragment</title></head><body>${input}</body></html>`;