func ShardBlockFromProto(sb *pb.ShardBlock) (*ShardBlock, error) {
	header, err := ShardBlockHeaderFromProto(sb.Header)
	if err != nil {
		return nil, err
	}

	body, err := ShardBlockBodyFromProto(sb.Body)
	if err != nil {
		return nil, err
	}

	return &ShardBlock{
		Header: *header,
		Body:   *body,
	}, nil
}
// ShardBlockFromProto converts a protobuf representation of shard block to a shard block.
ShardBlockFromProto converts a protobuf representation of shard block to a shard block.
// ShardBlockFromProto converts a protobuf representation of shard block to a shard block .
func ShardBlockFromProto(sb *pb.ShardBlock) (*ShardBlock, error) {
	header, err := ShardBlockHeaderFromProto(sb.Header)
	if err != nil {
		return nil, err
	}
	body, err := ShardBlockBodyFromProto(sb.Body)
	if err != nil {
		return nil, err
	}
	return &ShardBlock{
		Header: *header,
		Body:   *body,
	}, nil
}
func ShardBlockFromProto ( sb * pb . ShardBlock ) ( * ShardBlock , error ) { header , err := ShardBlockHeaderFromProto ( sb . Header ) if err != nil { return nil , err } body , err := ShardBlockBodyFromProto ( sb . Body ) if err != nil { return nil , err } return & ShardBlock { Header : * header , Body : * body , } , nil }
ShardBlockFromProto converts a protobuf representation of shard block to a shard block.
ShardBlockFromProto converts a protobuf representation of shard block to a shard block .