Skip to content
Merged
Changes from 1 commit
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
Prev Previous commit
Add bytecode address if TxKind is Call.
  • Loading branch information
Eric Bogard committed Jun 30, 2024
commit f5d164947e47e6942135015c8a680c0dc020a0a5
6 changes: 5 additions & 1 deletion crates/interpreter/src/interpreter/contract.rs
Original file line number Diff line number Diff line change
Expand Up @@ -60,12 +60,16 @@ impl Contract {
TxKind::Call(caller) => caller,
TxKind::Create => Address::ZERO,
};
let bytecode_address = match env.tx.transact_to {
TxKind::Call(caller) => Some(caller),
TxKind::Create => None,
};
Self::new(
env.tx.data.clone(),
bytecode,
hash,
contract_address,
None,
bytecode_address,
env.tx.caller,
env.tx.value,
)
Expand Down