Make validation::NetworkService strongly typed (#295)

By using a strongly typed network service, we make sure that we send and
receive the correct messages. Before there was a bug, a `SignedStatement`
was sent and a `GossipMessage` was decoded, but this could never work.
This commit is contained in:
Bastian Köcher
2019-06-24 11:43:07 +02:00
committed by GitHub
parent a016bac6ad
commit 664dea075a
6 changed files with 95 additions and 34 deletions
+1 -1
View File
@@ -69,7 +69,7 @@ mod benefit {
type FullStatus = GenericFullStatus<Block>;
/// Specialization of the network service for the polkadot protocol.
pub type NetworkService = ::substrate_network::NetworkService<Block, PolkadotProtocol>;
pub type NetworkService = substrate_network::NetworkService<Block, PolkadotProtocol>;
/// Status of a Polkadot node.
#[derive(Debug, PartialEq, Eq, Clone, Encode, Decode)]