mirror of
https://github.com/tig-foundation/tig-monorepo.git
synced 2026-02-21 10:27:49 +08:00
return to use n
This commit is contained in:
parent
9cfa3a2864
commit
8ec74900bb
@ -151,7 +151,7 @@ impl MerkleTree {
|
||||
}
|
||||
|
||||
pub fn calc_merkle_proof(&self, branch_idx: usize) -> Result<MerkleBranch> {
|
||||
if branch_idx >= self.hashed_leafs.len() {
|
||||
if branch_idx >= self.n {
|
||||
return Err(anyhow!("Invalid branch index"));
|
||||
}
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user