mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-06-13 02:21:14 +00:00
Clean up sc-network (#9761)
* Clean up sc-network - Avoid using clone() for the Copy type `PeerId`. - Use `find_map` for `filter_map` and `next`. - Use `Self`. * More on Copy types * Cargo +nightly fmt --all * More .. * fmt * Revert vec![default_notif_handshake_message]
This commit is contained in:
@@ -93,9 +93,9 @@ pub enum PeerEndpoint {
|
||||
impl From<ConnectedPoint> for PeerEndpoint {
|
||||
fn from(endpoint: ConnectedPoint) -> Self {
|
||||
match endpoint {
|
||||
ConnectedPoint::Dialer { address } => PeerEndpoint::Dialing(address),
|
||||
ConnectedPoint::Dialer { address } => Self::Dialing(address),
|
||||
ConnectedPoint::Listener { local_addr, send_back_addr } =>
|
||||
PeerEndpoint::Listening { local_addr, send_back_addr },
|
||||
Self::Listening { local_addr, send_back_addr },
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user