diff --git a/contracts/system-contracts/hedera-token-service/HederaTokenService.sol b/contracts/system-contracts/hedera-token-service/HederaTokenService.sol index 92f47946..f5df02ca 100644 --- a/contracts/system-contracts/hedera-token-service/HederaTokenService.sol +++ b/contracts/system-contracts/hedera-token-service/HederaTokenService.sol @@ -225,7 +225,7 @@ abstract contract HederaTokenService { /// @param token The ID of the token as a solidity address /// @dev This function reverts if the call is not successful function getTokenInfo(address token) internal returns (int responseCode, IHederaTokenService.TokenInfo memory tokenInfo) { - (bool success, bytes memory result) = precompileAddress.call( + (bool success, bytes memory result) = precompileAddress.staticcall( abi.encodeWithSelector(IHederaTokenService.getTokenInfo.selector, token)); IHederaTokenService.TokenInfo memory defaultTokenInfo; (responseCode, tokenInfo) = success ? abi.decode(result, (int32, IHederaTokenService.TokenInfo)) : (HederaResponseCodes.UNKNOWN, defaultTokenInfo); diff --git a/contracts/system-contracts/hedera-token-service/IHederaTokenService.sol b/contracts/system-contracts/hedera-token-service/IHederaTokenService.sol index 2df5b748..3475fbd2 100644 --- a/contracts/system-contracts/hedera-token-service/IHederaTokenService.sol +++ b/contracts/system-contracts/hedera-token-service/IHederaTokenService.sol @@ -689,7 +689,7 @@ interface IHederaTokenService { /// @return responseCode The response code for the status of the request. SUCCESS is 22. /// @return tokenInfo TokenInfo info for `token` function getTokenInfo(address token) - external + external view returns (int64 responseCode, TokenInfo memory tokenInfo); /// Query token KeyValue