Build your personal knowledge base with Trilium Notes
TypeScript electronelectron-appknowledge-baseknowledge-graphknowledge-managementknowledge-management-graphlocal-firstnote-managmentnote-takernote-takingnotebooknotesnotes-apppersonal-knowledge-basepersonal-wikiscriptableself-hostedself-hostingwiki
fix(react/type_widgets): relation map getting occassionally wiped
Elian Dorane8e93e985d53
diff --git a/apps/client/src/widgets/type_widgets/relation_map/RelationMap.tsx b/apps/client/src/widgets/type_widgets/relation_map/RelationMap.tsxindex 172c6a8cde..c342d257d3 100644--- a/apps/client/src/widgets/type_widgets/relation_map/RelationMap.tsx+++ b/apps/client/src/widgets/type_widgets/relation_map/RelationMap.tsx@@ -192,6 +192,8 @@ async function useRelationData(noteId: string, mapData: MapData | undefined, mapconst [ inverseRelations, setInverseRelations ] = useState<RelationMapPostResponse["inverseRelations"]>();async function refresh() {+ if (!noteIds) return;+const data = await server.post<RelationMapPostResponse>("relation-map", { noteIds, relationMapNoteId: noteId });const relations: ClientRelation[] = [];