diff --git a/src/merkle/mmr/peaks.rs b/src/merkle/mmr/peaks.rs index a3613fe8..a965ac7a 100644 --- a/src/merkle/mmr/peaks.rs +++ b/src/merkle/mmr/peaks.rs @@ -54,6 +54,11 @@ impl MmrPeaks { &self.peaks } + /// Returns the current num_leaves and peaks of the [Mmr]. + pub fn into_parts(self) -> (usize, Vec) { + (self.num_leaves, self.peaks) + } + /// Hashes the peaks. /// /// The procedure will: