Skip to content
This repository has been archived by the owner on Nov 6, 2020. It is now read-only.

Check queue to determine major importing #2763

Merged
merged 14 commits into from
Oct 20, 2016
Prev Previous commit
Next Next commit
fix merge
keorn committed Oct 18, 2016
commit 71281cc72f9afa053f945eb3a1a69fad80a3cd04
3 changes: 2 additions & 1 deletion rpc/src/v1/impls/eth.rs
Original file line number Diff line number Diff line change
@@ -253,7 +253,8 @@ impl<C, S: ?Sized, M, EM> Eth for EthClient<C, S, M, EM> where

fn syncing(&self) -> Result<SyncStatus, Error> {
try!(self.active());
if take_weak!(self.sync).status().is_major_syncing() {
let status = take_weak!(self.sync).status();
if status.is_major_syncing() {
let current_block = U256::from(take_weak!(self.client).chain_info().best_block_number);
let highest_block = U256::from(status.highest_block_number.unwrap_or(status.start_block_number));
let info = SyncInfo {