mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-07-24 05:36:46 +00:00
beacon, eth: null for missing cell
This commit is contained in:
parent
8389557759
commit
4fbdd4c189
2 changed files with 8 additions and 6 deletions
|
|
@ -158,8 +158,8 @@ type BlobAndProofV2 struct {
|
||||||
}
|
}
|
||||||
|
|
||||||
type BlobCellsAndProofsV1 struct {
|
type BlobCellsAndProofsV1 struct {
|
||||||
BlobCells []hexutil.Bytes `json:"blob_cells"`
|
BlobCells []*hexutil.Bytes `json:"blob_cells"`
|
||||||
Proofs []hexutil.Bytes `json:"proofs"`
|
Proofs []*hexutil.Bytes `json:"proofs"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// JSON type overrides for ExecutionPayloadEnvelope.
|
// JSON type overrides for ExecutionPayloadEnvelope.
|
||||||
|
|
|
||||||
|
|
@ -709,16 +709,18 @@ func (api *ConsensusAPI) GetBlobsV4(hashes []common.Hash, indicesBitarray types.
|
||||||
continue
|
continue
|
||||||
}
|
}
|
||||||
hitCount++
|
hitCount++
|
||||||
blobCells := make([]hexutil.Bytes, len(cells[i]))
|
blobCells := make([]*hexutil.Bytes, len(cells[i]))
|
||||||
for j, cell := range cells[i] {
|
for j, cell := range cells[i] {
|
||||||
if cell != nil {
|
if cell != nil {
|
||||||
blobCells[j] = cell[:]
|
b := hexutil.Bytes(cell[:])
|
||||||
|
blobCells[j] = &b
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
blobProofs := make([]hexutil.Bytes, len(proofs[i]))
|
blobProofs := make([]*hexutil.Bytes, len(proofs[i]))
|
||||||
for j, proof := range proofs[i] {
|
for j, proof := range proofs[i] {
|
||||||
if proof != nil {
|
if proof != nil {
|
||||||
blobProofs[j] = proof[:]
|
b := hexutil.Bytes(proof[:])
|
||||||
|
blobProofs[j] = &b
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
res[i] = &engine.BlobCellsAndProofsV1{
|
res[i] = &engine.BlobCellsAndProofsV1{
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue