evolutionlandorg / market-contracts

🏬Contracts for market
Apache License 2.0
19 stars 6 forks source link

Add claimTokens to support claim ERC721 tokens #54

Closed hackfisher closed 6 years ago

hackfisher commented 6 years ago
    function claimTokens(address _token) public onlyOwner {
        if (_token == 0x0) {
            owner.transfer(address(this).balance);
            return;
        }
        ERC20 token = ERC20(_token);
        uint balance = token.balanceOf(address(this));
        token.transfer(owner, balance);

        emit ClaimedTokens(_token, owner, balance);
    }
hackfisher commented 6 years ago

ERC721 tokens only support

function transferFrom(address _from, address _to, uint256 _tokenId) public;
hackfisher commented 6 years ago

since it is proxy, we can add this later by upgrading.