Skip to content

Commit 6f34b1b

Browse files
arijitADtimwu20
authored andcommitted
fix(dot/network): Fix missing digest in header (ChainSafe#2092)
* Fix missing digest in header
1 parent 8312490 commit 6f34b1b

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

dot/network/message.go

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,12 +8,13 @@ import (
88
"errors"
99
"fmt"
1010

11+
"google.golang.org/protobuf/proto"
12+
1113
pb "github.com/ChainSafe/gossamer/dot/network/proto"
1214
"github.com/ChainSafe/gossamer/dot/types"
1315
"github.com/ChainSafe/gossamer/lib/common"
1416
"github.com/ChainSafe/gossamer/lib/common/variadic"
1517
"github.com/ChainSafe/gossamer/pkg/scale"
16-
"google.golang.org/protobuf/proto"
1718
)
1819

1920
// Message types for notifications protocol messages. Used internally to map message to protocol.
@@ -305,8 +306,7 @@ func blockDataToProtobuf(bd *types.BlockData) (*pb.BlockData, error) {
305306

306307
func protobufToBlockData(pbd *pb.BlockData) (*types.BlockData, error) {
307308
bd := &types.BlockData{
308-
Hash: common.BytesToHash(pbd.Hash),
309-
Header: types.NewEmptyHeader(),
309+
Hash: common.BytesToHash(pbd.Hash),
310310
}
311311

312312
if pbd.Header != nil {

0 commit comments

Comments
 (0)