Skip to content

Commit

Permalink
Fix audittens I21 (#52)
Browse files Browse the repository at this point in the history
  • Loading branch information
StanislavBreadless authored Nov 29, 2024
1 parent 2edde4c commit 68d55a9
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions l1-contracts/contracts/state-transition/ChainTypeManager.sol
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ import {FeeParams} from "./chain-deps/ZKChainStorage.sol";
import {Ownable2StepUpgradeable} from "@openzeppelin/contracts-upgradeable-v4/access/Ownable2StepUpgradeable.sol";
import {ReentrancyGuard} from "../common/ReentrancyGuard.sol";
import {L2_TO_L1_LOG_SERIALIZE_SIZE, DEFAULT_L2_LOGS_TREE_ROOT_HASH, EMPTY_STRING_KECCAK} from "../common/Config.sol";
import {Unauthorized, ZeroAddress, HashMismatch, GenesisUpgradeZero, GenesisBatchHashZero, GenesisIndexStorageZero, GenesisBatchCommitmentZero} from "../common/L1ContractErrors.sol";
import {ChainAlreadyLive, Unauthorized, ZeroAddress, HashMismatch, GenesisUpgradeZero, GenesisBatchHashZero, GenesisIndexStorageZero, GenesisBatchCommitmentZero} from "../common/L1ContractErrors.sol";
import {SemVer} from "../common/libraries/SemVer.sol";
import {IBridgehub} from "../bridgehub/IBridgehub.sol";

Expand Down Expand Up @@ -354,7 +354,7 @@ contract ChainTypeManager is IChainTypeManager, ReentrancyGuard, Ownable2StepUpg
) internal returns (address zkChainAddress) {
if (getZKChain(_chainId) != address(0)) {
// ZKChain already registered
return getZKChain(_chainId);
revert ChainAlreadyLive();
}

// check not registered
Expand Down

0 comments on commit 68d55a9

Please sign in to comment.