Extract RPC definitions from RPC crate. (#3502)

* Extract author API from the substrate-rpc crate.

* Split out API from RPC.

* Clean up naming.

* Fix tests.

* Shorten error translations.

* Update Cargo.lock
This commit is contained in:
Tomasz Drwięga authored and Svyatoslav Nikolsky committed 2019-08-29 11:32:55 +03:00
1 parent 4ff97bd856
commit 98f64b6b93
28 files changed
+621 -409

No files matched your search

+3 -1
View File
@@ -725,7 +725,9 @@ fn build_network_future<
).collect());
}
rpc::system::Request::NetworkState(sender) => {
let _ = sender.send(network.network_state());
if let Some(network_state) = serde_json::to_value(&network.network_state()).ok() {
let _ = sender.send(network_state);
}
}
};
}