mirror of
https://github.com/YGGverse/aquatic.git
synced 2026-04-01 18:25:30 +00:00
announce handler: extract_response_peers: optimize
This commit is contained in:
parent
aa771f6a68
commit
3c411bdbf4
2 changed files with 4 additions and 4 deletions
|
|
@ -177,8 +177,10 @@ pub fn extract_response_peers(
|
|||
.collect()
|
||||
} else {
|
||||
peer_map.values()
|
||||
.map(Peer::to_response_peer)
|
||||
.choose_multiple(rng, number_of_peers_to_take)
|
||||
.into_iter()
|
||||
.map(Peer::to_response_peer)
|
||||
.collect()
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue