diff --git a/src/child/ChildERC20Bridge.sol b/src/child/ChildERC20Bridge.sol index 5b21bdda..06e3051b 100644 --- a/src/child/ChildERC20Bridge.sol +++ b/src/child/ChildERC20Bridge.sol @@ -51,7 +51,7 @@ contract ChildERC20Bridge is mapping(address => address) public rootTokenToChildToken; /// @dev Role identifier for those who can directly deposit native IMX to the bridge. - bytes32 public constant PREVILEGED_DEPOSITOR_ROLE = keccak256("PREVILEGED_DEPOSITOR"); + bytes32 public constant PRIVILEGED_DEPOSITOR_ROLE = keccak256("PRIVILEGED_DEPOSITOR"); bytes32 public constant MAP_TOKEN_SIG = keccak256("MAP_TOKEN"); bytes32 public constant DEPOSIT_SIG = keccak256("DEPOSIT"); @@ -114,8 +114,8 @@ contract ChildERC20Bridge is _grantRole(PAUSER_ROLE, newRoles.pauser); _grantRole(UNPAUSER_ROLE, newRoles.unpauser); _grantRole(ADAPTOR_MANAGER_ROLE, newRoles.adaptorManager); - _grantRole(PREVILEGED_DEPOSITOR_ROLE, newRoles.initialDepositor); - _grantRole(PREVILEGED_DEPOSITOR_ROLE, newRoles.treasuryManager); + _grantRole(PRIVILEGED_DEPOSITOR_ROLE, newRoles.initialDepositor); + _grantRole(PRIVILEGED_DEPOSITOR_ROLE, newRoles.treasuryManager); childTokenTemplate = newChildTokenTemplate; childBridgeAdaptor = IChildBridgeAdaptor(newBridgeAdaptor); @@ -152,7 +152,7 @@ contract ChildERC20Bridge is /** * @inheritdoc IChildERC20Bridge */ - function privilegedDeposit() external payable onlyRole(PREVILEGED_DEPOSITOR_ROLE) { + function privilegedDeposit() external payable onlyRole(PRIVILEGED_DEPOSITOR_ROLE) { if (msg.value == 0) { revert ZeroValue(); } diff --git a/src/interfaces/child/IChildERC20Bridge.sol b/src/interfaces/child/IChildERC20Bridge.sol index ee7e2060..6c3ba9bb 100644 --- a/src/interfaces/child/IChildERC20Bridge.sol +++ b/src/interfaces/child/IChildERC20Bridge.sol @@ -22,13 +22,13 @@ interface IChildERC20Bridge { address pauser; // The address which will inherit `PAUSER_ROLE`. address unpauser; // The address which will inherit `UNPAUSER_ROLE`. address adaptorManager; // The address which will inherit `ADAPTOR_MANAGER_ROLE`. - address initialDepositor; // The address which will inherit `PREVILEGED_DEPOSITOR_ROLE`. - address treasuryManager; // The address which will inherit `PREVILEGED_DEPOSITOR_ROLE`. + address initialDepositor; // The address which will inherit `PRIVILEGED_DEPOSITOR_ROLE`. + address treasuryManager; // The address which will inherit `PRIVILEGED_DEPOSITOR_ROLE`. } /** * @notice Deposit native IMX to the child chain bridge contract. - * @dev This function can only be called by callers who have the PREVILEGED_DEPOSITOR_ROLE. + * @dev This function can only be called by callers who have the PRIVILEGED_DEPOSITOR_ROLE. */ function privilegedDeposit() external payable; diff --git a/test/unit/child/ChildERC20Bridge.t.sol b/test/unit/child/ChildERC20Bridge.t.sol index b3f395c9..85386706 100644 --- a/test/unit/child/ChildERC20Bridge.t.sol +++ b/test/unit/child/ChildERC20Bridge.t.sol @@ -128,7 +128,7 @@ contract ChildERC20BridgeUnitTest is Test, IChildERC20BridgeEvents, IChildERC20B } function test_RevertsIf_privilegedDepositCalledFromNonTreasuryManager() public { - bytes32 role = childBridge.PREVILEGED_DEPOSITOR_ROLE(); + bytes32 role = childBridge.PRIVILEGED_DEPOSITOR_ROLE(); vm.expectRevert( abi.encodePacked( "AccessControl: account ",