diff --git a/static/js/modes/meshtastic.js b/static/js/modes/meshtastic.js index 133eb5d..2080f04 100644 --- a/static/js/modes/meshtastic.js +++ b/static/js/modes/meshtastic.js @@ -533,11 +533,17 @@ const Meshtastic = (function() { // Update markers for all nodes with positions data.nodes.forEach(node => { + // Track node in uniqueNodes set for stats + if (node.num) uniqueNodes.add(node.num); + if (node.has_position) { updateNodeMarker(node); } }); + // Update stats to reflect loaded nodes + updateStats(); + // Fit map to show all nodes if we have any const nodesWithPos = data.nodes.filter(n => n.has_position); if (nodesWithPos.length > 0 && meshMap) {