mirror of
https://gitlab.com/pulsechaincom/lighthouse-pulse.git
synced 2025-01-10 04:51:22 +00:00
return a BlobsUnavailable
error when the block root is a pre-4844 block
This commit is contained in:
parent
c6479444c2
commit
8e57eef0ed
@ -1068,7 +1068,10 @@ impl<T: BeaconChainTypes> BeaconChain<T> {
|
|||||||
// If there are no KZG commitments in the block, we know the sidecar should
|
// If there are no KZG commitments in the block, we know the sidecar should
|
||||||
// be empty.
|
// be empty.
|
||||||
let expected_kzg_commitments =
|
let expected_kzg_commitments =
|
||||||
block.message().body().blob_kzg_commitments()?;
|
match block.message().body().blob_kzg_commitments() {
|
||||||
|
Ok(kzg_commitments) => kzg_commitments,
|
||||||
|
Err(_) => return Err(Error::BlobsUnavailable),
|
||||||
|
};
|
||||||
if expected_kzg_commitments.is_empty() {
|
if expected_kzg_commitments.is_empty() {
|
||||||
Ok(Some(BlobsSidecar::empty_from_parts(
|
Ok(Some(BlobsSidecar::empty_from_parts(
|
||||||
*block_root,
|
*block_root,
|
||||||
|
Loading…
Reference in New Issue
Block a user