src/exporter/node_store: Fix garbage collection

This commit is contained in:
Max Inden 2020-04-21 17:56:58 +02:00
parent 8d90004ebf
commit 0f18a40bb8
No known key found for this signature in database
GPG Key ID: 5403C5464810BC26

View File

@ -42,7 +42,7 @@ impl NodeStore {
// Remove old offline nodes.
let length = self.nodes.len();
self.nodes
.retain(|_, n| (Instant::now() - n.last_seen) > Duration::from_secs(60 * 60 * 24));
.retain(|_, n| (Instant::now() - n.last_seen) < Duration::from_secs(60 * 60 * 24));
self.metrics
.meta_offline_nodes_removed
.with_label_values(&[&self.dht])