Is it possible to withdraw eth from weth contract from my smart contract? Transactions succeed but my contract is not getting the ether deposited...
Feb 9, 2021, 5:56 PM
you can wrap/unwrap it.
Feb 9, 2021, 5:59 PM
you should be able to call the "withdraw" function. remember to add allowance first
Feb 9, 2021, 6:07 PM
Can I add allowance using delegatecall?
Feb 9, 2021, 6:08 PM
I guess, but don't know why you'd want to.
Feb 9, 2021, 6:10 PM
I mean, who is getting the weth is my contract, not my address. So I have to add allowance from my contract to the weth address I guess. I just want to discard problems...
Feb 9, 2021, 6:12 PM
just be very careful about stuff like delegatecall and don't use those unless you really know you need it.
you're basically just asking for trouble if you use delegatecall without reallyreally needing it
Feb 9, 2021, 6:14 PM
Yeah thanks. My problem was it is needed to add an external payable function to receive ether from the weth contract
Feb 9, 2021, 11:10 PM