mirror of
https://github.com/zadam/trilium.git
synced 2025-10-26 07:46:30 +01:00
server: Fix import of non-text files
This commit is contained in:
@@ -49,9 +49,6 @@ function importImage(file: File, parentNote: BNote, taskContext: TaskContext) {
|
||||
}
|
||||
|
||||
function importFile(taskContext: TaskContext, file: File, parentNote: BNote) {
|
||||
if (typeof file.buffer !== "string") {
|
||||
throw new Error("Invalid file content for text.");
|
||||
}
|
||||
const originalName = file.originalname;
|
||||
|
||||
const {note} = noteService.createNewNote({
|
||||
|
||||
Reference in New Issue
Block a user