Skip to content

Commit

Permalink
Merge of #5345
Browse files Browse the repository at this point in the history
  • Loading branch information
mergify[bot] committed Mar 7, 2024
2 parents a05b141 + d5dee22 commit 6839f46
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions beacon_node/lighthouse_network/src/peer_manager/mod.rs
Expand Up @@ -880,8 +880,7 @@ impl<TSpec: EthSpec> PeerManager<TSpec> {
let outbound_only_peer_count = self.network_globals.connected_outbound_only_peers();
let wanted_peers = if peer_count < self.target_peers.saturating_sub(dialing_peers) {
// We need more peers in general.
// Note: The maximum discovery query is bounded by `Discovery`.
self.target_peers.saturating_sub(dialing_peers) - peer_count
self.max_peers().saturating_sub(dialing_peers) - peer_count
} else if outbound_only_peer_count < self.min_outbound_only_peers()
&& peer_count < self.max_outbound_dialing_peers()
{
Expand Down

0 comments on commit 6839f46

Please sign in to comment.