Skip to content

Commit

Permalink
cargo fmt
Browse files Browse the repository at this point in the history
  • Loading branch information
intx4 committed Jan 22, 2024
1 parent aad2785 commit 76846e1
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions src/merkle_tree/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -508,7 +508,7 @@ impl<P: Config> MerkleTree<P> {
}

/// Given the `index` of a leaf, returns the digest of its leaf sibling
pub fn get_leaf_sibling_hash(&self, index: usize) -> P::LeafDigest{
pub fn get_leaf_sibling_hash(&self, index: usize) -> P::LeafDigest {
if index & 1 == 0 {
// leaf is left child
self.leaf_nodes[index + 1].clone()
Expand Down Expand Up @@ -578,7 +578,6 @@ impl<P: Config> MerkleTree<P> {
let mut prev_path = Vec::new();

for index in &indexes {

leaf_siblings_hashes.push(self.get_leaf_sibling_hash(*index));

let path = self.compute_auth_path(*index);
Expand Down

0 comments on commit 76846e1

Please sign in to comment.