Let's suppose here are 2 EOA(A and B) and 1 contract. A has no token, B has 10token(erc20).
- A approve B to spend 10token(do not consider gas)
- B execute 2 functions in turn following via contract in single TX
- transfer 10token to A
- transferfrom A to B 10token
Is this logic possible? If not, how can I make it? The point is step2 should be made in single TX.