Skip to content

Commit

Permalink
Applied further PR comments
Browse files Browse the repository at this point in the history
  • Loading branch information
viquezclaudio authored and jsdanielh committed Mar 3, 2023
1 parent f121544 commit 22f575c
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion network-libp2p/src/connection_pool/behaviour.rs
Original file line number Diff line number Diff line change
Expand Up @@ -365,7 +365,7 @@ impl ConnectionPoolBehaviour {
}

/// This function is used to select a list of peers, based on services flag, in order to dial them.
/// num_peers is used to specify how many peers are selected
/// `num_peers` is used to specify how many peers are selected
/// The number of peers returned equals num_peers unless there are less available peers
pub fn choose_peers_to_dial_by_services(
&self,
Expand Down
4 changes: 2 additions & 2 deletions network-libp2p/src/network.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1781,8 +1781,8 @@ impl NetworkInterface for Network {
}
}

// If we don't have enough connected peer that support the desired services,
// we tell the network to connect to new peers that supports such services.
// If we don't have enough connected peers that support the desired services,
// we tell the network to connect to new peers that support such services.
if filtered_peers.len() < min_peers {
let num_peers = min_peers - filtered_peers.len();

Expand Down

0 comments on commit 22f575c

Please sign in to comment.