Skip to main content

tip_block

Function tip_block 

Source
pub fn tip_block<C>(
    chain: Option<C>,
    db: &ZebraDb,
) -> Result<Option<Arc<Block>>, BlockReadError>
where C: AsRef<Chain>,
Expand description

Returns the tip block of chain. If there is no chain, returns the tip of db.

Returns an error if primary data is incomplete. An incomplete secondary view returns None.