fix setting mime after import + cleanup of old search code

This commit is contained in:
zadam
2020-08-18 22:20:47 +02:00
parent 03d7ee9abb
commit 53c361945b
10 changed files with 13 additions and 371 deletions

View File

@@ -105,7 +105,7 @@ function createNewNote(params) {
throw new Error(`Note title must not be empty`);
}
sql.transactional(() => {
return sql.transactional(() => {
const note = new Note({
noteId: params.noteId, // optionally can force specific noteId
title: params.title,
@@ -744,8 +744,8 @@ function duplicateNote(noteId, parentNoteId) {
const newNote = new Note(origNote);
newNote.noteId = undefined; // force creation of new note
newNote.title += " (dup)";
newNote.save();
newNote.setContent(origNote.getContent());
const newBranch = new Branch({