converted if() throw convention to require()/assert()/revert()
This commit is contained in:
committed by
Francisco Giordano
parent
f3867f8477
commit
18581f138f
@ -3,7 +3,7 @@ pragma solidity ^0.4.11;
|
||||
import "./Ownable.sol";
|
||||
import "../token/ERC20Basic.sol";
|
||||
|
||||
/**
|
||||
/**
|
||||
* @title Contracts that should not own Tokens
|
||||
* @author Remco Bloemen <remco@2π.com>
|
||||
* @dev This blocks incoming ERC23 tokens to prevent accidental loss of tokens.
|
||||
@ -12,14 +12,14 @@ import "../token/ERC20Basic.sol";
|
||||
*/
|
||||
contract HasNoTokens is Ownable {
|
||||
|
||||
/**
|
||||
/**
|
||||
* @dev Reject all ERC23 compatible tokens
|
||||
* @param from_ address The address that is transferring the tokens
|
||||
* @param value_ uint256 the amount of the specified token
|
||||
* @param data_ Bytes The data passed from the caller.
|
||||
*/
|
||||
function tokenFallback(address from_, uint256 value_, bytes data_) external {
|
||||
throw;
|
||||
revert();
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user