Avoid loading unecessary data

This commit is contained in:
Emilia Hane 2023-01-06 11:17:15 +01:00
parent 88dde8b3bb
commit caad492d48
No known key found for this signature in database
GPG Key ID: E73394F9C09206FA

View File

@ -1055,7 +1055,7 @@ impl<T: BeaconChainTypes> BeaconChain<T> {
match self.store.get_blobs(block_root)? {
Some(blobs) => Ok(Some(blobs)),
None => {
if let Some(block) = self.get_block(block_root).await? {
if let Ok(Some(block)) = self.get_blinded_block(block_root) {
let expected_kzg_commitments = block.message().body().blob_kzg_commitments()?;
if expected_kzg_commitments.len() > 0 {