meshstats: don't count undefined as gateway

This commit is contained in:
Milan Paessler 2016-06-02 23:17:06 +02:00
parent 93355f28ba
commit 4c6ba69dd3

View file

@ -15,7 +15,9 @@ define(function () {
return d.statistics.gateway return d.statistics.gateway
}).concat(d.nodes.all.filter( function (d) { }).concat(d.nodes.all.filter( function (d) {
return d.flags.gateway return d.flags.gateway
})))).map(one)) })))).map(function(d) {
return (typeof d === "string") ? 1 : 0
}))
var nodetext = [{ count: totalOnlineNodes, label: "online" }, var nodetext = [{ count: totalOnlineNodes, label: "online" },
{ count: totalNewNodes, label: "neu" }, { count: totalNewNodes, label: "neu" },