MCPcopy Create free account
hub / github.com/massCodeIO/massCode / updateNote

Function updateNote

src/renderer/composables/spaces/notes/useNotes.ts:546–558  ·  view source on GitHub ↗
(noteId: number, data: NotesUpdate)

Source from the content-addressed store, hash-verified

544}
545
546async function updateNote(noteId: number, data: NotesUpdate) {
547 markPersistedStorageMutation()
548 await api.notes.patchNotesById(String(noteId), data)
549
550 if (isNoteListMembershipAffecting(data)) {
551 await getNotes(queryByLibraryOrFolderOrSearch.value)
552 await refreshSelectedNote()
553 return
554 }
555
556 // Переименование/описание не меняют состав списка — обновляем точечно.
557 patchNoteInCollections(noteId, data)
558}
559
560async function updateNotes(noteIds: number[], data: NotesUpdate[]) {
561 markPersistedStorageMutation()

Callers 2

useNoteUpdate.tsFile · 0.70
deleteSelectedNotesFunction · 0.70

Calls 5

refreshSelectedNoteFunction · 0.85
patchNoteInCollectionsFunction · 0.85
getNotesFunction · 0.70

Tested by

no test coverage detected