MCPcopy Create free account
hub / github.com/base/base / commit_initial_state

Method commit_initial_state

crates/execution/trie/src/in_memory.rs:1008–1016  ·  view source on GitHub ↗
(&self)

Source from the content-addressed store, hash-verified

1006 }
1007
1008 fn commit_initial_state(&self) -> BaseProofsStorageResult<BlockNumHash> {
1009 let mut inner = self.inner.write();
1010 if let Some((number, hash)) = inner.anchor_block {
1011 inner.earliest_block = Some((number, hash));
1012 Ok(BlockNumHash::new(number, hash))
1013 } else {
1014 Err(BaseProofsStorageError::NoBlocksFound)
1015 }
1016 }
1017}
1018
1019#[cfg(test)]

Callers

nothing calls this directly

Calls 2

newFunction · 0.50
writeMethod · 0.45

Tested by

no test coverage detected