Remove CanReclaimToken (#1306)

This commit is contained in:
Leo Arias
2018-09-07 11:01:37 -06:00
committed by Francisco Giordano
parent 6cae0f458d
commit bafdcf0701
2 changed files with 0 additions and 66 deletions

View File

@ -1,26 +0,0 @@
pragma solidity ^0.4.24;
import "./Ownable.sol";
import "../token/ERC20/IERC20.sol";
import "../token/ERC20/SafeERC20.sol";
/**
* @title Contracts that should be able to recover tokens
* @author SylTi
* @dev This allow a contract to recover any ERC20 token received in a contract by transferring the balance to the contract owner.
* This will prevent any accidental loss of tokens.
*/
contract CanReclaimToken is Ownable {
using SafeERC20 for IERC20;
/**
* @dev Reclaim all ERC20 compatible tokens
* @param token ERC20 The address of the token contract
*/
function reclaimToken(IERC20 token) external onlyOwner {
uint256 balance = token.balanceOf(this);
token.safeTransfer(owner(), balance);
}
}