Add constant modifier to ERC721_RECEIVED magic value
This commit is contained in:
@ -13,8 +13,9 @@ contract ERC721BasicToken is ERC721Basic {
|
||||
using SafeMath for uint256;
|
||||
using AddressUtils for address;
|
||||
|
||||
// Equals to bytes4(keccak256("onERC721Received(address,uint256,bytes)"))
|
||||
bytes4 ERC721_RECEIVED = 0xf0b9e5ba;
|
||||
// Equals to `bytes4(keccak256("onERC721Received(address,uint256,bytes)"))`
|
||||
// which can be also obtained as `ERC721Receiver(0).onERC721Received.selector`
|
||||
bytes4 constant ERC721_RECEIVED = 0xf0b9e5ba;
|
||||
|
||||
// Mapping from token ID to owner
|
||||
mapping (uint256 => address) internal tokenOwner;
|
||||
|
||||
@ -8,9 +8,10 @@ pragma solidity ^0.4.18;
|
||||
contract ERC721Receiver {
|
||||
/**
|
||||
* @dev Magic value to be returned upon successful reception of an NFT
|
||||
* Equals to bytes4(keccak256("onERC721Received(address,uint256,bytes)"))
|
||||
* Equals to `bytes4(keccak256("onERC721Received(address,uint256,bytes)"))`,
|
||||
* which can be also obtained as `ERC721Receiver(0).onERC721Received.selector`
|
||||
*/
|
||||
bytes4 ERC721_RECEIVED = 0xf0b9e5ba;
|
||||
bytes4 constant ERC721_RECEIVED = 0xf0b9e5ba;
|
||||
|
||||
/**
|
||||
* @notice Handle the receipt of an NFT
|
||||
|
||||
Reference in New Issue
Block a user