Skip to content

Commit

Permalink
Revert "Improve gap calculation"
Browse files Browse the repository at this point in the history
This reverts commit 9fa04a4.
  • Loading branch information
shargon committed May 13, 2020
1 parent b5d9dff commit e920732
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/neo/Consensus/ConsensusService.cs
Original file line number Diff line number Diff line change
Expand Up @@ -307,7 +307,9 @@ private void OnConsensusPayload(ConsensusPayload payload)
private void OnPersistCompleted(Block block)
{
Log($"persist block: height={block.Index} hash={block.Hash} tx={block.Transactions.Length}");
block_received_time = TimeProvider.Current.UtcNow;
DateTime now = TimeProvider.Current.UtcNow;
block_received_gap = now - block_received_time;
block_received_time = now;
knownHashes.Clear();
InitializeConsensus(0);
}
Expand Down

1 comment on commit e920732

@shargon
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

My mistake, wrong branch ...

Please sign in to comment.