Skip to content
This repository was archived by the owner on Jul 22, 2024. It is now read-only.

Add hash_value to l1 handler new #802

Merged
merged 3 commits into from
Jul 11, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 19 additions & 1 deletion src/transaction/l1_handler.rs
Original file line number Diff line number Diff line change
Expand Up @@ -58,8 +58,26 @@ impl L1Handler {
&[nonce.clone()],
)?;

Ok(L1Handler {
L1Handler::new_with_tx_hash(
contract_address,
entry_point_selector,
calldata,
nonce,
paid_fee_on_l1,
hash_value,
)
}

pub fn new_with_tx_hash(
contract_address: Address,
entry_point_selector: Felt252,
calldata: Vec<Felt252>,
nonce: Felt252,
paid_fee_on_l1: Option<Felt252>,
tx_hash: Felt252,
) -> Result<L1Handler, TransactionError> {
Ok(L1Handler {
hash_value: tx_hash,
contract_address,
entry_point_selector,
calldata,
Expand Down