fix putting new attribute correctly into becca

This commit is contained in:
zadam
2022-06-17 23:04:46 +02:00
parent 540aba39db
commit 5ca7e39852
4 changed files with 5 additions and 8 deletions

View File

@@ -91,10 +91,7 @@ function addNoteAttribute(req) {
const noteId = req.params.noteId;
const body = req.body;
const attr = new Attribute(body);
attr.noteId = noteId;
attr.save();
new Attribute({...body, noteId}).save();
}
function deleteNoteAttribute(req) {