Correct boolean NOT on is_fresh_dial

This commit is contained in:
Luke Parker 2024-04-21 07:30:18 -04:00
parent 320b5627b5
commit e01848aa9e
No known key found for this signature in database

View file

@ -333,8 +333,8 @@ impl LibP2p {
let (is_fresh_dial, nets) = {
let mut dialing_peers = dialing_peers.write().await;
let is_fresh_dial = dialing_peers.contains_key(&addr);
if !is_fresh_dial {
let is_fresh_dial = !dialing_peers.contains_key(&addr);
if is_fresh_dial {
dialing_peers.insert(addr.clone(), HashSet::new());
}
// Associate this network with this peer