Skip to content
This repository has been archived by the owner on Aug 2, 2024. It is now read-only.

Commit

Permalink
doc: fix event commitment documentation typo (#1187)
Browse files Browse the repository at this point in the history
  • Loading branch information
antiyro authored Oct 12, 2023
1 parent dfb29ff commit 629f36c
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

## Next release

- fix: event commitment documentation typo
- ci: added testing key generation in the ci
- fix(starknet-rpc-test): init one request client per runtime
- test: validate Nonce for unsigned user txs
Expand Down
6 changes: 3 additions & 3 deletions crates/primitives/commitments/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -161,7 +161,7 @@ pub(crate) fn calculate_transaction_commitment<H: HasherT>(
tree.commit()
}

/// Calculate transaction commitment hash value.
/// Calculate event commitment hash value.
///
/// The event commitment is the root of the Patricia Merkle tree with height 64
/// constructed by adding the event hash
Expand All @@ -170,11 +170,11 @@ pub(crate) fn calculate_transaction_commitment<H: HasherT>(
///
/// # Arguments
///
/// * `transactions` - The transactions to get the events from.
/// * `events` - The events to calculate the commitment from.
///
/// # Returns
///
/// The merkle root of the merkle tree built from the transactions and the number of events.
/// The merkle root of the merkle tree built from the events.
pub(crate) fn calculate_event_commitment<H: HasherT>(events: &[Event]) -> Felt252Wrapper {
let mut tree = CommitmentTree::<H>::default();
events.iter().enumerate().for_each(|(id, event)| {
Expand Down

0 comments on commit 629f36c

Please sign in to comment.