MCPcopy Create free account
hub / github.com/atomicdotdev/atomic / full_hash

Function full_hash

atomic-cli/src/commands/rpc.rs:201–211  ·  view source on GitHub ↗
(hash: &Option<pb::Hash>)

Source from the content-addressed store, hash-verified

199}
200
201fn full_hash(hash: &Option<pb::Hash>) -> String {
202 hash.as_ref()
203 .and_then(|h| {
204 h.value
205 .clone()
206 .try_into()
207 .ok()
208 .map(|bytes: [u8; 32]| Merkle(bytes).to_base32())
209 })
210 .unwrap_or_else(|| "-".to_string())
211}
212
213// ---------------------------------------------------------------------------
214// status

Callers 2

unrecord_previewFunction · 0.85
agent_explainFunction · 0.85

Calls 5

MerkleClass · 0.85
as_refMethod · 0.80
okMethod · 0.45
cloneMethod · 0.45
to_base32Method · 0.45

Tested by

no test coverage detected