Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions types/state.go
Original file line number Diff line number Diff line change
Expand Up @@ -136,9 +136,9 @@ func (s State) AssertValidSequence(header *SignedHeader) error {
return fmt.Errorf("%w - got: %v, last: %v", ErrInvalidBlockTime, headerTime, s.LastBlockTime)
}

// Trick to support the switch from a base sequencer to a normal syncing node.
// Based sequencers do not sign ehaders, meaning the last header hash will be different from the
// newly derived header hash when a base sequencer have switched to a syncing node
// Trick to support the switch from a based sequencer to a normal syncing node.
// Based sequencers do not sign headers, meaning the last header hash will be different from the
// newly derived header hash when a based sequencer has switched to a syncing node.
if !bytes.Equal(header.LastHeaderHash, s.LastHeaderHash) {
if lastHeaderHashErrCount == 1 {
return fmt.Errorf("%w - got: %x, want: %x", ErrInvalidLastHeaderHash, header.LastHeaderHash, s.LastHeaderHash)
Expand Down