mirror of
https://github.com/status-im/consul.git
synced 2025-02-08 20:05:09 +00:00
Don't include self in tomography
This commit is contained in:
parent
ba6d402e85
commit
885dd87fec
@ -289,10 +289,11 @@ App.NodesShowRoute = App.BaseRoute.extend({
|
|||||||
dc.coordinates.forEach(function (node) {
|
dc.coordinates.forEach(function (node) {
|
||||||
if (params.name == node.Node) {
|
if (params.name == node.Node) {
|
||||||
dc.coordinates.forEach(function (other) {
|
dc.coordinates.forEach(function (other) {
|
||||||
// TODO: ignore self
|
if (node.Node != other.Node) {
|
||||||
var dist = distance(node, other);
|
var dist = distance(node, other);
|
||||||
distances.push(dist);
|
distances.push(dist);
|
||||||
sum += dist;
|
sum += dist;
|
||||||
|
}
|
||||||
});
|
});
|
||||||
distances.sort();
|
distances.sort();
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user