diff --git a/l1-contracts/deploy-scripts/dev/SetupLegacyBridge.s.sol b/l1-contracts/deploy-scripts/dev/SetupLegacyBridge.s.sol index 301bfd2c8..e178824b1 100644 --- a/l1-contracts/deploy-scripts/dev/SetupLegacyBridge.s.sol +++ b/l1-contracts/deploy-scripts/dev/SetupLegacyBridge.s.sol @@ -104,6 +104,7 @@ contract SetupLegacyBridge is Script { function setParamsForDummyBridge() internal { (address l2TokenBeacon, bytes32 l2TokenBeaconHash) = calculateTokenBeaconAddress(); DummyL1ERC20Bridge bridge = DummyL1ERC20Bridge(addresses.erc20BridgeProxy); + vm.broadcast(); bridge.setValues(config.l2SharedBridgeAddress, l2TokenBeacon, l2TokenBeaconHash); } @@ -124,10 +125,15 @@ contract SetupLegacyBridge is Script { bytes memory beaconProxy = Utils.readHardhatBytecode( "/../l2-contracts/artifacts-zk/@openzeppelin/contracts/proxy/beacon/BeaconProxy.sol/BeaconProxy.json" ); + tokenBeaconBytecodeHash = L2ContractHelper.hashL2Bytecode(beaconProxy); - (tokenBeaconAddress, tokenBeaconBytecodeHash) = calculateL2Create2Address( + bytes memory upgradableBeacon = Utils.readHardhatBytecode( + "/../l2-contracts/artifacts-zk/@openzeppelin/contracts/proxy/beacon/UpgradeableBeacon.sol/UpgradeableBeacon.json" + ); + + (tokenBeaconAddress, ) = calculateL2Create2Address( config.l2SharedBridgeAddress, - beaconProxy, + upgradableBeacon, bytes32(0), abi.encode(l2StandardToken) );