diff --git a/src/services/import/samples/UTF-16LE Text Note.txt b/src/services/import/samples/UTF-16LE Text Note.txt new file mode 100644 index 000000000..c76e1ddd7 Binary files /dev/null and b/src/services/import/samples/UTF-16LE Text Note.txt differ diff --git a/src/services/import/single.spec.ts b/src/services/import/single.spec.ts index f4e0cff11..6e35ebe1a 100644 --- a/src/services/import/single.spec.ts +++ b/src/services/import/single.spec.ts @@ -66,4 +66,10 @@ describe("processNoteContent", () => { expect(importedNote.mime).toBe("application/json"); expect(importedNote.getContent().toString()).toStrictEqual(stripBom(buffer.toString("utf-16le"))); }); + + it("supports plain text note with UTF-16", async () => { + const { importedNote } = await testImport("UTF-16LE Text Note.txt", "text/plain"); + expect(importedNote.mime).toBe("text/html"); + expect(importedNote.getContent().toString()).toBe("
Plain text goes here.