in `transferTo()` function - You forgot to change `msg.sender.transfer(amount)` - to `to.transfer(amount)`