This commit is contained in:
hinto.janai 2024-09-17 20:36:04 -04:00
parent 0f4939a318
commit 669e5a2120
No known key found for this signature in database
GPG key ID: D47CE05FA175A499
2 changed files with 5 additions and 7 deletions

View file

@ -40,7 +40,9 @@ impl<Z: NetworkZone, AdrBook, CSync, PSync, ProtoHdlr, BrdcstStrmMkr>
Connector<Z, AdrBook, CSync, PSync, ProtoHdlr, BrdcstStrmMkr>
{
/// Create a new connector from a handshaker.
pub const fn new(handshaker: HandShaker<Z, AdrBook, CSync, PSync, ProtoHdlr, BrdcstStrmMkr>) -> Self {
pub const fn new(
handshaker: HandShaker<Z, AdrBook, CSync, PSync, ProtoHdlr, BrdcstStrmMkr>,
) -> Self {
Self { handshaker }
}
}

View file

@ -13,9 +13,7 @@ impl From<ProtocolRequest> for ProtocolMessage {
match value {
ProtocolRequest::GetObjects(val) => Self::GetObjectsRequest(val),
ProtocolRequest::GetChain(val) => Self::ChainRequest(val),
ProtocolRequest::FluffyMissingTxs(val) => {
Self::FluffyMissingTransactionsRequest(val)
}
ProtocolRequest::FluffyMissingTxs(val) => Self::FluffyMissingTransactionsRequest(val),
ProtocolRequest::GetTxPoolCompliment(val) => Self::GetTxPoolCompliment(val),
ProtocolRequest::NewBlock(val) => Self::NewBlock(val),
ProtocolRequest::NewFluffyBlock(val) => Self::NewFluffyBlock(val),
@ -31,9 +29,7 @@ impl TryFrom<ProtocolMessage> for ProtocolRequest {
Ok(match value {
ProtocolMessage::GetObjectsRequest(val) => Self::GetObjects(val),
ProtocolMessage::ChainRequest(val) => Self::GetChain(val),
ProtocolMessage::FluffyMissingTransactionsRequest(val) => {
Self::FluffyMissingTxs(val)
}
ProtocolMessage::FluffyMissingTransactionsRequest(val) => Self::FluffyMissingTxs(val),
ProtocolMessage::GetTxPoolCompliment(val) => Self::GetTxPoolCompliment(val),
ProtocolMessage::NewBlock(val) => Self::NewBlock(val),
ProtocolMessage::NewFluffyBlock(val) => Self::NewFluffyBlock(val),