diff --git a/crates/primitives/src/transaction/mod.rs b/crates/primitives/src/transaction/mod.rs index 9c95bb04e290..db7b49a9330e 100644 --- a/crates/primitives/src/transaction/mod.rs +++ b/crates/primitives/src/transaction/mod.rs @@ -1179,10 +1179,7 @@ impl<'a> arbitrary::Arbitrary<'a> for TransactionSigned { signature }; - let mut tx = TransactionSigned { hash: Default::default(), signature, transaction }; - tx.hash = tx.recalculate_hash(); - - Ok(tx) + Ok(TransactionSigned::from_transaction_and_signature(transaction, signature)) } }