Closed rozzaswap closed 2 months ago
Name | Link |
---|---|
Latest commit | 7cbeed1da27ca69868e2341d5b49420b6a0d6578 |
Latest deploy log | https://app.netlify.com/sites/telos-bridge/deploys/667bfb9a12e640000869c667 |
Deploy Preview | https://deploy-preview-104--telos-bridge.netlify.app |
Preview on mobile | Toggle QR Code...Use your smartphone camera to open QR code link. |
To edit notification comments on pull requests, go to your Netlify site configuration.
Name | Link |
---|---|
Latest commit | 7cbeed1da27ca69868e2341d5b49420b6a0d6578 |
Latest deploy log | https://app.netlify.com/sites/sparkly-dasik-ad5e27/deploys/667bfb9ad113fb0008f7fd81 |
Deploy Preview | https://deploy-preview-104--sparkly-dasik-ad5e27.netlify.app |
Preview on mobile | Toggle QR Code...Use your smartphone camera to open QR code link. |
To edit notification comments on pull requests, go to your Netlify site configuration.
Fixes #101
Description
This PR includes a fix for the problem of not getting the gas estimation right for the approvals before the actual transaction.
approve
transaction with the exact amount entered by the user.These changes did not require the library to be modified.
Test scenarios
You gotta have at least 5 USTD in the Ethereum chain and some ETH to pay the fees.
go to USDT contract code on etherscan.
allowed
read function using your address as the first argument and the bridge contract (0x9c5ebCbE531aA81bD82013aBF97401f5C6111d76) as the second.approve
function with the contract address as the spender and the value with the amount desired (enter1000000
for 1USDT)select USDT from the Ethereum blockchain as the origin
select Telos EVM as the destination
play with different values and check all of them pass throw with no errors
Cases are: 1 - you have More approval than you are willing to transfer. Best case: you don't need to approve anything. 2 - you cave 0 approval. Normal case: This will cause you to only approve the Transaction without resetting anything. 3 - you have some but not enough approval. Rarest case: This will trigger the reset and then the exact approval you need.
Screenshots
telos-bridge--resetting-approvals.webm