diff --git a/codex/stores/repostore.nim b/codex/stores/repostore.nim index 3343382e..37c54972 100644 --- a/codex/stores/repostore.nim +++ b/codex/stores/repostore.nim @@ -100,6 +100,12 @@ proc decode(_: type (Cid, MerkleProof), data: seq[byte]): ?!(Cid, MerkleProof) = proof = ? MerkleProof.decode(data[sizeof(uint64) + n..^1]) success((cid, proof)) +proc decodeCid(_: type (Cid, MerkleProof), data: seq[byte]): ?!Cid = + let + n = uint64.fromBytesBE(data[0..