Skip to content

Commit

Permalink
fix: add setGasLimit
Browse files Browse the repository at this point in the history
  • Loading branch information
fadeev committed Dec 18, 2024
1 parent fd3d640 commit 4952436
Show file tree
Hide file tree
Showing 4 changed files with 20 additions and 0 deletions.
5 changes: 5 additions & 0 deletions contracts/nft/contracts/evm/UniversalNFT.sol
Original file line number Diff line number Diff line change
Expand Up @@ -62,6 +62,11 @@ contract UniversalNFT is
gateway = GatewayEVM(gatewayAddress);
}

function setGasLimit(uint256 gas) external onlyOwner {
if (gas <= 0) revert InvalidGasLimit();
gasLimitAmount = gas;
}

function setUniversal(address contractAddress) external onlyOwner {
if (contractAddress == address(0)) revert InvalidAddress();
universal = contractAddress;
Expand Down
5 changes: 5 additions & 0 deletions contracts/nft/contracts/zetachain/UniversalNFT.sol
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,11 @@ contract UniversalNFT is
gasLimitAmount = gas;
}

function setGasLimit(uint256 gas) external onlyOwner {
if (gas <= 0) revert InvalidGasLimit();
gasLimitAmount = gas;
}

function setConnected(
address zrc20,
address contractAddress
Expand Down
5 changes: 5 additions & 0 deletions contracts/token/contracts/evm/UniversalToken.sol
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,11 @@ contract UniversalToken is
gateway = GatewayEVM(gatewayAddress);
}

function setGasLimit(uint256 gas) external onlyOwner {
if (gas <= 0) revert InvalidGasLimit();
gasLimitAmount = gas;
}

function setUniversal(address contractAddress) external onlyOwner {
if (contractAddress == address(0)) revert InvalidAddress();
universal = contractAddress;
Expand Down
5 changes: 5 additions & 0 deletions contracts/token/contracts/zetachain/UniversalToken.sol
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,11 @@ contract UniversalToken is
gasLimitAmount = gas;
}

function setGasLimit(uint256 gas) external onlyOwner {
if (gas <= 0) revert InvalidGasLimit();
gasLimitAmount = gas;
}

function setConnected(
address zrc20,
address contractAddress
Expand Down

0 comments on commit 4952436

Please sign in to comment.