From a71a049176455413b3520459cfe4b9324f6b39dd Mon Sep 17 00:00:00 2001 From: Stanislav Bezkorovainyi Date: Mon, 2 Dec 2024 16:00:46 +0100 Subject: [PATCH] Fix audittens I23 (#53) --- l1-contracts/contracts/bridgehub/Bridgehub.sol | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/l1-contracts/contracts/bridgehub/Bridgehub.sol b/l1-contracts/contracts/bridgehub/Bridgehub.sol index ea99d137f..50ea311a1 100644 --- a/l1-contracts/contracts/bridgehub/Bridgehub.sol +++ b/l1-contracts/contracts/bridgehub/Bridgehub.sol @@ -246,7 +246,10 @@ contract Bridgehub is IBridgehub, ReentrancyGuard, Ownable2StepUpgradeable, Paus address token = __DEPRECATED_baseToken[_chainId]; require(token != address(0), "BH: token not set"); - baseTokenAssetId[_chainId] = DataEncoding.encodeNTVAssetId(block.chainid, token); + bytes32 assetId = DataEncoding.encodeNTVAssetId(block.chainid, token); + + baseTokenAssetId[_chainId] = assetId; + assetIdIsRegistered[assetId] = true; address chainAddress = IChainTypeManager(ctm).getZKChainLegacy(_chainId); if (chainAddress == address(0)) {