Skip to content

Commit 4203b56

Browse files
committed
add consensus version header
1 parent 37c9b67 commit 4203b56

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

beacon_node/http_api/src/aggregate_attestation.rs

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
use crate::unsupported_version_rejection;
2-
use crate::version::{V1, V2};
2+
use crate::version::{add_consensus_version_header, V1, V2};
33
use beacon_chain::{BeaconChain, BeaconChainTypes};
44
use eth2::types::{EndpointVersion, Hash256, Slot};
55
use std::sync::Arc;
@@ -40,7 +40,10 @@ pub fn get_aggregate_attestation<T: BeaconChainTypes>(
4040
metadata: EmptyMetadata {},
4141
data: aggregate_attestation,
4242
};
43-
Ok(warp::reply::json(&fork_versioned_response).into_response())
43+
Ok(add_consensus_version_header(
44+
warp::reply::json(&fork_versioned_response).into_response(),
45+
fork_name,
46+
))
4447
} else if endpoint_version == V1 {
4548
let aggregate_attestation = chain
4649
.get_pre_electra_aggregated_attestation_by_slot_and_root(slot, attestation_data_root)

0 commit comments

Comments
 (0)