crypto/kzg4844: remove redundant check in gokzgRecoverBlobs

This commit is contained in:
Felix Lange 2026-04-23 12:57:33 +02:00
parent 63f35121a1
commit 22bcf90bf0

View file

@ -18,7 +18,6 @@ package kzg4844
import (
"encoding/json"
"errors"
"sync"
gokzg4844 "github.com/crate-crypto/go-eth-kzg"
@ -204,10 +203,6 @@ func gokzgComputeCells(blobs []Blob) ([]Cell, error) {
func gokzgRecoverBlobs(cells []Cell, cellIndices []uint64) ([]Blob, error) {
gokzgIniter.Do(gokzgInit)
if len(cellIndices) == 0 || len(cells)%len(cellIndices) != 0 {
return []Blob{}, errors.New("cells with wrong length")
}
blobCount := len(cells) / len(cellIndices)
blobs := make([]Blob, 0, blobCount)