Skip to content

Commit f388f7d

Browse files
pslaskibsuieric
authored andcommitted
etcm-643 fixed execution of InternalLastBlockImport in BlockFetcher
1 parent fb67c34 commit f388f7d

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

src/main/scala/io/iohk/ethereum/blockchain/sync/regular/BlockFetcher.scala

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -278,8 +278,7 @@ class BlockFetcher(
278278
//keep fetcher state updated in case new checkpoint block or mined block was imported
279279
case InternalLastBlockImport(blockNr) =>
280280
log.debug(s"New last block $blockNr imported from the inside")
281-
val newLastBlock = blockNr.max(state.lastBlock)
282-
val newState = state.withLastBlock(newLastBlock).withPossibleNewTopAt(blockNr)
281+
val newState = state.withLastBlock(blockNr).withPossibleNewTopAt(blockNr)
283282

284283
fetchBlocks(newState)
285284
}

0 commit comments

Comments
 (0)