Commit 0b3ba9f9 authored by Luc Didry's avatar Luc Didry

Fix unexistent nodes issue

parent 7a320d6e
Pipeline #112905 passed with stages
in 5 minutes and 34 seconds
......@@ -212,11 +212,11 @@ $ua->get($node.'/wot/members' => sub {
var w2 = Math.round(100000 * (total - ed.length)/total) / 1000;
document.getElementById('w3-progress-text').textContent = w2+'%';
console.info('Adding edge');
if (edg.from !== undefined && ne[edg.from] === undefined) {
if (edg.from !== undefined && n[edg.from] !== undefined && ne[edg.from] === undefined) {
nodes.add(n[edg.from]);
ne[edg.from] = 1;
}
if (edg.to !== undefined && ne[edg.to] === undefined) {
if (edg.to !== undefined && n[edg.to] !== undefined && ne[edg.to] === undefined) {
nodes.add(n[edg.to]);
ne[edg.to] = 1;
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment