I have few child wallets and a parent wallet.
Whenever these child wallets get incoming ERC20 tokens or ETH. I want to send them automatically to the parent wallet.
I know I can do below to send the entire eth balance.
beneficiary.transfer(this.balance);
How can I do it for erc20 tokens.
Thanks in advance.
Best Answer
You are looking to effectively 'forward' your balance. A way to go about doing this is using a contract similar to the one highlighted Here.