Skip to content

Commit

Permalink
Jesus review II
Browse files Browse the repository at this point in the history
  • Loading branch information
ignasirv committed Feb 28, 2025
1 parent 303ced0 commit 16b8904
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 15 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ contract GlobalExitRootManagerL2SovereignChain is
function initialize(
address _globalExitRootUpdater,
address _globalExitRootRemover
) external virtual reinitializer(2) {
) external virtual initializer {
// set globalExitRootUpdater
globalExitRootUpdater = _globalExitRootUpdater;
// set globalExitRootRemover
Expand Down
2 changes: 1 addition & 1 deletion src/constants.js
Original file line number Diff line number Diff line change
Expand Up @@ -41,4 +41,4 @@ TIMELOCK.MINDELAY_STORAGE_POS = 2;
/// /////////////////////////////////
module.exports.STORAGE_ONE_VALUE = '0x0000000000000000000000000000000000000000000000000000000000000001';
module.exports.STORAGE_ZERO_VALUE = '0x0000000000000000000000000000000000000000000000000000000000000000';
module.exports.NO_ADDRESS = '0xFFfFfFffFFfffFFfFFfFFFFFffFFFffffFfFFFfF';
module.exports.NO_ADDRESS = '0xFFfFfFffFFfffFFfFFfFFFFFffFFFffffFfFFFfF';
4 changes: 0 additions & 4 deletions test/contractsv2/BridgeL2SovereignChainUpgradeAL.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -92,10 +92,6 @@ describe("BridgeL2SovereignChain Contract", () => {
}
)) as unknown as GlobalExitRootManagerL2SovereignChain;

// initialize GlobalExitRootManagerL2SovereignChain
await sovereignChainGlobalExitRootContract.initialize(
ethers.ZeroAddress, deployer.address
);
// cannot initialize bridgeV2 initializer from Sovereign bridge
await expect(
sovereignChainBridgeContract.initialize(
Expand Down
11 changes: 2 additions & 9 deletions upgrade/upgradeSovereign/upgradeSovereignGER.ts
Original file line number Diff line number Diff line change
Expand Up @@ -94,20 +94,13 @@ async function main() {
);
console.log("Copy the following constructor arguments on: upgrade/arguments.js \n", [bridgeAddress]);
}
// Get initialize values
const globalExitRootUpdater = await gerManagerL2SovereignChainContract.globalExitRootUpdater();
const globalExitRootRemover = await gerManagerL2SovereignChainContract.globalExitRootRemover();

// gerManagerL2SovereignChainImplementation is upgraded but not initialized
const timelockOperation = genTimelockOperation(
proxyAdmin.target,
0, // value
proxyAdmin.interface.encodeFunctionData("upgradeAndCall", [
proxyAdmin.interface.encodeFunctionData("upgrade", [
globalExitRootManagerL2SovereignChainAddress,
gerManagerL2SovereignChainImplementation,
gerManagerL2SovereignChainFactory.interface.encodeFunctionData("initialize", [
globalExitRootUpdater,
globalExitRootRemover,
]),
]), // data
ethers.ZeroHash, // predecessor
salt // salt
Expand Down

0 comments on commit 16b8904

Please sign in to comment.