Skip to content

Commit 353e994

Browse files
committed
chore: add a EMPTY_LEAF const
1 parent cdfca8e commit 353e994

File tree

2 files changed

+2
-3
lines changed

2 files changed

+2
-3
lines changed

src/group.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,6 @@ pub struct Group {
4747
/// Hashed LeanIMT
4848
pub tree: HashedLeanIMT<ELEMENT_SIZE, PoseidonHash>,
4949
}
50-
pub type MerkleProof = LeanIMTMerkleProof;
5150

5251
impl Group {
5352
/// Creates a new instance of the Group with optional initial members

src/proof.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
use crate::{
2-
group::{Group, MerkleProof},
2+
group::{Group, MerkleProof, EMPTY_LEAF},
33
identity::Identity,
44
utils::{hash, to_big_uint},
55
MAX_TREE_DEPTH, MIN_TREE_DEPTH,
@@ -91,7 +91,7 @@ impl Proof {
9191
if let Some(sibling) = merkle_proof.siblings.get(i as usize) {
9292
merkle_proof_siblings.push(sibling.clone());
9393
} else {
94-
merkle_proof_siblings.push("0".to_string());
94+
merkle_proof_siblings.push(EMPTY_LEAF.to_string());
9595
}
9696
}
9797

0 commit comments

Comments
 (0)