I have a function that uses the ERC20 transfer function to send an ERC20 token from a smart contract to another wallet address.
function withdrawTokens(address _tokenContract, uint256 _amount) external onlyOwner {
IERC20 tokenContract = IERC20(_tokenContract);
tokenContract.transfer(_wallet, _amount);
emit FundsWithdrawn(_wallet, _amount);
}
For some reason this is not working for sending Tether USDT (0xdac17f958d2ee523a2206206994597c13d831ec7
) out of the contract, but it does work for sending USDC. Is Tether non ERC-20 compliant? How do I implement this function to work for USDT?