From 4e05b5f10833109bdcad710cb31485528d28cb74 Mon Sep 17 00:00:00 2001 From: William Banfield Date: Thu, 19 May 2022 12:31:50 -0400 Subject: [PATCH] ensure extensions on extended commit save --- internal/store/store.go | 3 +++ 1 file changed, 3 insertions(+) diff --git a/internal/store/store.go b/internal/store/store.go index 1a500fb00..7b8679b69 100644 --- a/internal/store/store.go +++ b/internal/store/store.go @@ -497,6 +497,9 @@ func (bs *BlockStore) SaveBlockWithExtendedCommit(block *types.Block, blockParts if block == nil { panic("BlockStore can only save a non-nil block") } + if err := seenExtendedCommit.EnsureExtensions(); err != nil { + panic(fmt.Sprintf("saving block with extensions %w", err)) + } batch := bs.db.NewBatch() if err := bs.saveBlockToBatch(batch, block, blockParts, seenExtendedCommit.ToCommit()); err != nil { panic(err)