don't count offline nodes

alfred-data
Nils Schneider 2012-06-16 05:04:21 +02:00
parent 86307665fc
commit cb716e297d
1 changed files with 3 additions and 3 deletions

View File

@ -344,13 +344,13 @@ function reload() {
updated_at.text(d3.time.format("%X")(new Date()))
var nNodes = data.nodes.filter(function(d) {
return !d.flags.client
return !d.flags.client && d.flags.online
}).length,
nGateways = data.nodes.filter(function(d) {
return d.flags.gateway
return d.flags.gateway && d.flags.online
}).length,
nClients = data.nodes.filter(function(d) {
return d.flags.client
return d.flags.client && d.flags.online
}).length
d3.select("#nodecount")