From 6eb57a77763ff39e10bf97fb02ca23e8c7b6b017 Mon Sep 17 00:00:00 2001 From: Vladyslav Burtsevych Date: Mon, 23 Dec 2024 14:34:43 +0100 Subject: [PATCH] fix: compile fix --- .../transparent-proxy/TransparentProxyFactoryZkSync.sol | 2 +- zksync/src/contracts/utils/ScriptUtilsZkSync.sol | 4 +++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/zksync/src/contracts/transparent-proxy/TransparentProxyFactoryZkSync.sol b/zksync/src/contracts/transparent-proxy/TransparentProxyFactoryZkSync.sol index c937b78..39556cf 100644 --- a/zksync/src/contracts/transparent-proxy/TransparentProxyFactoryZkSync.sol +++ b/zksync/src/contracts/transparent-proxy/TransparentProxyFactoryZkSync.sol @@ -21,7 +21,7 @@ contract TransparentProxyFactoryZkSync is TransparentProxyFactoryBase { ) internal pure override returns (address) { bytes32 addressHash = keccak256( bytes.concat( - ZKSYNC_CREATE2_PREFIX, + Create2UtilsZkSync.ZKSYNC_CREATE2_PREFIX, bytes32(uint256(uint160(sender))), salt, Create2UtilsZkSync.getBytecodeHashFromBytecode(creationCode), diff --git a/zksync/src/contracts/utils/ScriptUtilsZkSync.sol b/zksync/src/contracts/utils/ScriptUtilsZkSync.sol index 8b087f1..18977bf 100644 --- a/zksync/src/contracts/utils/ScriptUtilsZkSync.sol +++ b/zksync/src/contracts/utils/ScriptUtilsZkSync.sol @@ -32,6 +32,8 @@ library Create2UtilsZkSync { // https://github.com/matter-labs/era-contracts/blob/main/system-contracts/contracts/Create2Factory.sol address public constant CREATE2_FACTORY = 0x0000000000000000000000000000000000010000; + bytes32 public constant ZKSYNC_CREATE2_PREFIX = keccak256('zksyncCreate2'); + /** * @dev Deploys a contract using the CREATE2 opcode. * @param salt A salt to influence the address of the deployed contract. @@ -158,7 +160,7 @@ library Create2UtilsZkSync { ) internal pure returns (address) { bytes32 addressHash = keccak256( bytes.concat( - keccak256('zksyncCreate2'), // zkSync create2 prefix + ZKSYNC_CREATE2_PREFIX, bytes32(uint256(uint160(CREATE2_FACTORY))), salt, bytecodeHash,