Skip to content

Fix duplicate DB write and log in UpdateHeadBlock#10648

Open
davidjsonn wants to merge 2 commits intoNethermindEth:masterfrom
davidjsonn:fix/remove-duplicate-updateheadblock
Open

Fix duplicate DB write and log in UpdateHeadBlock#10648
davidjsonn wants to merge 2 commits intoNethermindEth:masterfrom
davidjsonn:fix/remove-duplicate-updateheadblock

Conversation

@davidjsonn
Copy link
Contributor

Remove duplicate log and DB write in UpdateHeadBlock.

The log message and _blockInfoDb.Set() were called twice: once before the header lookup, and again inside the success branch.
This change also ensures the DB write only occurs when the header is found.

@LukaszRozmej
Copy link
Member

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants