From 3133214e4f47d6456ad3b4ffc717d4d91d2ee3f2 Mon Sep 17 00:00:00 2001 From: Henry de Valence Date: Wed, 9 Sep 2020 21:19:15 -0700 Subject: [PATCH] zebrad: use new state API --- zebrad/src/components/sync.rs | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/zebrad/src/components/sync.rs b/zebrad/src/components/sync.rs index c1a2d277..912c7a6b 100644 --- a/zebrad/src/components/sync.rs +++ b/zebrad/src/components/sync.rs @@ -312,12 +312,10 @@ where .ready_and() .await .map_err(|e| eyre!(e))? - .call(zebra_state::Request::GetBlockLocator { - genesis: self.genesis_hash, - }) + .call(zebra_state::Request::BlockLocator) .await .map(|response| match response { - zebra_state::Response::BlockLocator { block_locator } => block_locator, + zebra_state::Response::BlockLocator(block_locator) => block_locator, _ => unreachable!( "GetBlockLocator request can only result in Response::BlockLocator" ), @@ -654,7 +652,7 @@ where .ready_and() .await .map_err(|e| eyre!(e))? - .call(zebra_state::Request::GetDepth { hash }) + .call(zebra_state::Request::Depth(hash)) .await .map_err(|e| eyre!(e))? {