mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-06-14 04:01:10 +00:00
@@ -254,7 +254,7 @@ impl Metrics {
|
||||
.inc_by(num);
|
||||
self.notifications_sizes
|
||||
.with_label_values(&[protocol, "sent", name])
|
||||
.inc_by(num.saturating_mul(u64::try_from(message.len()).unwrap_or(u64::max_value())));
|
||||
.inc_by(num.saturating_mul(u64::try_from(message.len()).unwrap_or(u64::MAX)));
|
||||
}
|
||||
},
|
||||
}
|
||||
@@ -294,7 +294,7 @@ impl Metrics {
|
||||
.inc();
|
||||
self.notifications_sizes
|
||||
.with_label_values(&[&protocol, "received", name])
|
||||
.inc_by(u64::try_from(message.len()).unwrap_or(u64::max_value()));
|
||||
.inc_by(u64::try_from(message.len()).unwrap_or(u64::MAX));
|
||||
}
|
||||
},
|
||||
}
|
||||
|
||||
@@ -345,7 +345,7 @@ fn lots_of_incoming_peers_works() {
|
||||
fallback_names: Vec::new(),
|
||||
max_notification_size: 1024 * 1024,
|
||||
set_config: config::SetConfig {
|
||||
in_peers: u32::max_value(),
|
||||
in_peers: u32::MAX,
|
||||
.. Default::default()
|
||||
},
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user