MCPcopy Index your code
hub / github.com/avoidwork/tiny-graph / del

Method del

lib/tiny-graph.js:48–58  ·  view source on GitHub ↗
(x, y)

Source from the content-addressed store, hash-verified

46 }
47
48 del (x, y) {
49 let result = false;
50
51 if (defined(this.nodes[x]) && defined(this.nodes[x].edges[y])) {
52 delete this.nodes[x].edges[y];
53 delete this.nodes[y].edges[x];
54 result = true;
55 }
56
57 return result;
58 }
59
60 delNode (x) {
61 const n = this.nodes[x];

Callers

nothing calls this directly

Calls 1

definedFunction · 0.70

Tested by

no test coverage detected