I have an ERC20 test contract, also I did multicall with delegatecall
function instead of call
.
I have a three accounts: account1, account2, and account3.
account1 can spend tokens from account2 (I did transaction here, and this is works)
Then I tried to send the same transaction with multicall contract, and I got an error: ERC20: insufficient allowance
, here a callstack
So I see in both transactions allowance call, but in the second transaction I see allowance as 0. How to fix that? and why that happened?