Skip to content

Commit

Permalink
Add allowList and totalDepositedAmountPerUser mappings
Browse files Browse the repository at this point in the history
  • Loading branch information
juan518munoz committed Jan 25, 2024
1 parent c1e815b commit 1e368aa
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions l1-contracts/contracts/bridge/L1ERC20Bridge.sol
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,9 @@ import {AddressAliasHelper} from "../vendor/AddressAliasHelper.sol";
contract L1ERC20Bridge is IL1Bridge, IL1BridgeLegacy, ReentrancyGuard {
using SafeERC20 for IERC20;

/// @dev The smart contract that manages the list with permission to call contract functions
IAllowList internal immutable allowList;

/// @dev zkSync smart contract that is used to operate with L2 via asynchronous L2 <-> L1 communication
IZkSync internal immutable zkSync;

Expand Down Expand Up @@ -61,6 +64,10 @@ contract L1ERC20Bridge is IL1Bridge, IL1BridgeLegacy, ReentrancyGuard {
/// @dev A mapping L1 token address => user address => the total deposited amount by the user
mapping(address => mapping(address => uint256)) private __DEPRECATED_totalDepositedAmountPerUser;

/// @dev The accumulated deposited amount per user.
/// @dev A mapping L1 token address => user address => the total deposited amount by the user
mapping(address => mapping(address => uint256)) public totalDepositedAmountPerUser;

/// @dev Contract is expected to be used as proxy implementation.
/// @dev Initialize the implementation to prevent Parity hack.
constructor(IZkSync _zkSync) reentrancyGuardInitializer {
Expand Down

0 comments on commit 1e368aa

Please sign in to comment.