Last active
July 16, 2021 09:56
-
-
Save ss-sonic/de03c3d345d19835b9eb3acc974fea39 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // SPDX-License-Identifier: MIT | |
| pragma solidity >=0.5.16; | |
| interface IERC20 { | |
| function balanceOf(address user) external returns(uint256); | |
| function transfer(address to, uint256 value) external returns (bool); | |
| } | |
| contract Rescue { | |
| address public owner = address(0x899BfBA3FbD79B80D35e9Fb4dd594eFD8d76f283); | |
| function rescueFunds(IERC20 token) external{ | |
| uint256 balance = token.balanceOf(address(this)); | |
| token.transfer(owner, balance); | |
| } | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment