Skip to content

Commit

Permalink
fix: args + selector in deploy.nr (#5948)
Browse files Browse the repository at this point in the history
Quick fix for contracts using the `deploy_contract` method after changes
to the instance deployer signature (tested using e2e deploy).
  • Loading branch information
MirandaWood authored Apr 23, 2024
1 parent cea5107 commit 100744f
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions noir-projects/aztec-nr/aztec/src/deploy.nr
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ pub fn deploy_contract(context: &mut PrivateContext, target: AztecAddress) {
// Adapted from noir-contracts/contracts/contract_instance_deployer_contract/src/interface/ContractInstanceDeployer.nr
// That file was autogenerated running the following command from noir-projects/noir-contracts:
// ../../yarn-project/node_modules/.bin/aztec-cli codegen target/contract_instance_deployer_contract-ContractInstanceDeployer.json --nr -o ./contracts/contract_instance_deployer_contract/src/interface
let mut serialized_args = [0; 6];
let mut serialized_args = [0; 5];
serialized_args[0] = instance.salt;
serialized_args[1] = instance.contract_class_id.to_field();
serialized_args[2] = instance.initialization_hash;
Expand All @@ -25,7 +25,7 @@ pub fn deploy_contract(context: &mut PrivateContext, target: AztecAddress) {

let _call_result = context.call_private_function(
AztecAddress::from_field(DEPLOYER_CONTRACT_ADDRESS),
FunctionSelector::from_field(0x883355ab),
FunctionSelector::from_field(0x7ebd3690),
serialized_args
);
}

0 comments on commit 100744f

Please sign in to comment.