I'm calling a function of one of my contracts with the same parameters twice in a row (locally). The gas spent by the first transaction is 178,310
, while the gas spent by the second transaction is only 156,710
.
let result = await instance.myFunction(amount,list,rates,tokens,{from:accounts[1],value:web3.utils.toWei("20","ether")})
The difference is exactly 21,600
gas, I'm wondering if it has anything to do with the gas cost of a value transfer?
Thanks