Skip to content

Commit

Permalink
Update RootERC20Bridge.sol
Browse files Browse the repository at this point in the history
  • Loading branch information
wcgcyx committed Nov 13, 2023
1 parent 822246a commit 635b110
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/root/RootERC20Bridge.sol
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ contract RootERC20Bridge is
bytes32 public constant VARIABLE_MANAGER_ROLE = keccak256("VARIABLE_MANAGER_ROLE");
bytes32 public constant ADAPTOR_MANAGER_ROLE = keccak256("ADAPTOR_MANAGER_ROLE");

uint256 public constant NO_DEPOSIT_LIMIT = 0;
uint256 public constant UNLIMITED_DEPOSIT = 0;
bytes32 public constant MAP_TOKEN_SIG = keccak256("MAP_TOKEN");
bytes32 public constant DEPOSIT_SIG = keccak256("DEPOSIT");
bytes32 public constant WITHDRAW_SIG = keccak256("WITHDRAW");
Expand Down Expand Up @@ -161,7 +161,7 @@ contract RootERC20Bridge is
}

if (
newImxCumulativeDepositLimit != NO_DEPOSIT_LIMIT
newImxCumulativeDepositLimit != UNLIMITED_DEPOSIT
&& newImxCumulativeDepositLimit < IERC20Metadata(rootIMXToken).balanceOf(address(this))
) {
revert ImxDepositLimitTooLow();
Expand Down Expand Up @@ -331,7 +331,7 @@ contract RootERC20Bridge is
revert ZeroAmount();
}
if (
address(rootToken) == rootIMXToken && imxCumulativeDepositLimit != NO_DEPOSIT_LIMIT
address(rootToken) == rootIMXToken && imxCumulativeDepositLimit != UNLIMITED_DEPOSIT
&& IERC20Metadata(rootIMXToken).balanceOf(address(this)) + amount > imxCumulativeDepositLimit
) {
revert ImxDepositLimitExceeded();
Expand Down

0 comments on commit 635b110

Please sign in to comment.