mirror of
https://github.com/zadam/trilium.git
synced 2025-10-28 16:56:34 +01:00
trigger events after note attributes are created
This commit is contained in:
@@ -68,9 +68,6 @@ async function createNewNote(parentNoteId, noteData) {
|
||||
isExpanded: 0
|
||||
}).save();
|
||||
|
||||
await triggerNoteTitleChanged(note);
|
||||
await triggerChildNoteCreated(note, parentNote);
|
||||
|
||||
for (const attr of await parentNote.getAttributes()) {
|
||||
if (attr.name.startsWith("child:")) {
|
||||
await new Attribute({
|
||||
@@ -86,6 +83,9 @@ async function createNewNote(parentNoteId, noteData) {
|
||||
}
|
||||
}
|
||||
|
||||
await triggerNoteTitleChanged(note);
|
||||
await triggerChildNoteCreated(note, parentNote);
|
||||
|
||||
return {
|
||||
note,
|
||||
branch
|
||||
|
||||
Reference in New Issue
Block a user