// Move address in the list to the front i.g. the first address that will be tried when dialing the target.
Move address in the list to the front i.g. the first address that will be tried when dialing the target.
Move address in the list to the front i . g . the first address that will be tried when dialing the target .
pub fn prioritize_addr(&mut self, peer: PeerId, addr: Multiaddr) {
        let peer_addr = self.peers.entry(peer).or_default();
        if peer_addr.known.front() != Some(&addr) {
            peer_addr.known.retain(|a| a != &addr);
            peer_addr.known.push_front(addr);
        }
    }
pub fn prioritize_addr ( & mut self , peer : PeerId , addr : Multiaddr ) { let peer_addr = self . peers . entry ( peer ) . or_default ( ) ; if peer_addr . known . front ( ) != Some ( & addr ) { peer_addr . known . retain ( | a | a != & addr ) ; peer_addr . known . push_front ( addr ) ; } }
Move address in the list to the front i.g.
Move address in the list to the front i . g .
&mut self
peer
PeerId
addr
Multiaddr