Skip to content

Commit

Permalink
cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
skosito committed Oct 23, 2024
1 parent 4df01e3 commit 39e72fe
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 9 deletions.
8 changes: 4 additions & 4 deletions v2/contracts/evm/GatewayEVM.sol
Original file line number Diff line number Diff line change
Expand Up @@ -110,9 +110,9 @@ contract GatewayEVM is
)
public
payable
nonReentrant
onlyRole(TSS_ROLE)
whenNotPaused
nonReentrant
{
if (destination == address(0)) revert ZeroAddress();
(bool success,) = destination.call{ value: msg.value }("");
Expand All @@ -135,9 +135,9 @@ contract GatewayEVM is
)
external
payable
nonReentrant
onlyRole(TSS_ROLE)
whenNotPaused
nonReentrant
returns (bytes memory)
{
if (destination == address(0)) revert ZeroAddress();
Expand Down Expand Up @@ -172,9 +172,9 @@ contract GatewayEVM is
bytes calldata data
)
public
nonReentrant
onlyRole(ASSET_HANDLER_ROLE)
whenNotPaused
nonReentrant
{
if (amount == 0) revert InsufficientERC20Amount();
if (to == address(0)) revert ZeroAddress();
Expand Down Expand Up @@ -217,9 +217,9 @@ contract GatewayEVM is
RevertContext calldata revertContext
)
external
nonReentrant
onlyRole(ASSET_HANDLER_ROLE)
whenNotPaused
nonReentrant
{
if (amount == 0) revert InsufficientERC20Amount();
if (to == address(0)) revert ZeroAddress();
Expand Down
10 changes: 5 additions & 5 deletions v2/contracts/zevm/GatewayZEVM.sol
Original file line number Diff line number Diff line change
Expand Up @@ -338,9 +338,9 @@ contract GatewayZEVM is
bytes calldata message
)
external
nonReentrant
onlyProtocol
whenNotPaused
nonReentrant
{
if (zrc20 == address(0) || target == address(0)) revert ZeroAddress();

Expand All @@ -361,9 +361,9 @@ contract GatewayZEVM is
bytes calldata message
)
external
nonReentrant
onlyProtocol
whenNotPaused
nonReentrant
{
if (zrc20 == address(0) || target == address(0)) revert ZeroAddress();
if (amount == 0) revert InsufficientZRC20Amount();
Expand All @@ -385,9 +385,9 @@ contract GatewayZEVM is
bytes calldata message
)
external
nonReentrant
onlyProtocol
whenNotPaused
nonReentrant
{
if (target == address(0)) revert ZeroAddress();
if (amount == 0) revert InsufficientZetaAmount();
Expand All @@ -400,7 +400,7 @@ contract GatewayZEVM is
/// @notice Revert a user-specified contract on ZEVM.
/// @param target The target contract to call.
/// @param revertContext Revert context to pass to onRevert.
function executeRevert(address target, RevertContext calldata revertContext) external onlyProtocol whenNotPaused nonReentrant {
function executeRevert(address target, RevertContext calldata revertContext) external nonReentrant onlyProtocol whenNotPaused {
if (target == address(0)) revert ZeroAddress();

Revertable(target).onRevert(revertContext);
Expand All @@ -418,9 +418,9 @@ contract GatewayZEVM is
RevertContext calldata revertContext
)
external
nonReentrant
onlyProtocol
whenNotPaused
nonReentrant
{
if (zrc20 == address(0) || target == address(0)) revert ZeroAddress();
if (amount == 0) revert InsufficientZRC20Amount();
Expand Down

0 comments on commit 39e72fe

Please sign in to comment.