contract, that i deployed to 4 chains(Fantom, Avalnche, Polygon and Ethereun) using truffle. On all chains except Ethereum it works great, but at Ethereum the "main" method of contract crashes every time. So i deployed it by remix and got this error: Gas estimation errored with the following message (see below). The transaction execution will likely fail. Do you want to force sending?
execution reverted. why is it possible that contract which works on all chains include test doesnt work on ethereum? Thanks for any help
In addition, method failed where i call _safeTransferFrom inside
post the code of the main function, otherwise it's kinda hard to find the problem. Probably an external address you're calling
Before this lines just "requires" that successfully passes every time _safeTransferFrom(usdtToken, msg.sender, tokenWallet, _amount); _safeTransferFrom(tokenForSale, tokenWallet, msg.sender, amountSelled); emit Swap(msg.sender, _amount, amountSelled);
Обсуждают сегодня