Added error logging for duplicate edges in rawGraph.

This commit is contained in:
yangdx
2025-03-18 09:51:53 +08:00
parent 217ffa9e05
commit 77c23a23e4
3 changed files with 4 additions and 2 deletions

View File

@@ -8,7 +8,7 @@
<link rel="icon" type="image/svg+xml" href="logo.png" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>Lightrag</title>
<script type="module" crossorigin src="./assets/index-DSwGiLVk.js"></script>
<script type="module" crossorigin src="./assets/index-D6vUNmAf.js"></script>
<link rel="stylesheet" crossorigin href="./assets/index-mPRIIErN.css">
</head>
<body>

View File

@@ -595,6 +595,8 @@ const useLightrangeGraph = () => {
rawGraph.edgeIdMap[newEdge.id] = rawGraph.edges.length - 1;
// Update dynamic edge map
rawGraph.edgeDynamicIdMap[newEdge.dynamicId] = rawGraph.edges.length - 1;
} else {
console.error('Edge already exists in rawGraph:', newEdge.id);
}
}