ghost-eye/src/network/raw_calls/historical.rs
Uncle Stinky 2e0205a581
sketch for the validators page
Signed-off-by: Uncle Stinky <uncle.stinky@ghostchain.io>
2025-01-19 18:04:02 +03:00

20 lines
480 B
Rust

use color_eyre::Result;
use subxt::{
utils::H256,
client::OnlineClient,
};
use crate::{
casper_network,
CasperConfig,
};
pub async fn stored_range(
online_client: &OnlineClient<CasperConfig>,
at_hash: Option<&H256>,
) -> Result<Option<(u32, u32)>> {
let storage_key = casper_network::storage().historical().stored_range();
let maybe_stored_range = super::do_storage_call(online_client, &storage_key, at_hash).await?;
Ok(maybe_stored_range)
}