Skip to content

Commit

Permalink
feat: constructor for AccountUpdate
Browse files Browse the repository at this point in the history
  • Loading branch information
polydez committed Apr 22, 2024
1 parent fa6e0fd commit 57eb86c
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions objects/src/transaction/proven_tx.rs
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,11 @@ pub struct AccountUpdate {
}

impl AccountUpdate {
/// Creates a new [AccountUpdate].
pub const fn new(init_hash: Digest, final_hash: Digest, details: AccountUpdateDetails) -> Self {
Self { init_hash, final_hash, details }
}

/// Returns the initial account state hash.
pub fn init_hash(&self) -> Digest {
self.init_hash
Expand Down

0 comments on commit 57eb86c

Please sign in to comment.