Skip to content

Commit

Permalink
feat: destroyToken transfer to 0xdead (#15)
Browse files Browse the repository at this point in the history
  • Loading branch information
justussoh authored Sep 30, 2020
1 parent 74d2d75 commit e81fe8e
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion contracts/ERC721.sol
Original file line number Diff line number Diff line change
Expand Up @@ -1247,7 +1247,8 @@ contract TradeTrustERC721 is ERC721MintableFull, IERC721Receiver {

function destroyToken(uint256 _tokenId) public onlyMinter {
require(ownerOf(_tokenId) == address(this), "Cannot destroy token: Token not owned by token registry");
_burn(_tokenId);
// Burning token to 0xdead instead to show a differentiate state as address(0) is used for unminted tokens
_safeTransferFrom(ownerOf(_tokenId), 0x000000000000000000000000000000000000dEaD, _tokenId, "");
emit TokenBurnt(_tokenId);
}

Expand Down

0 comments on commit e81fe8e

Please sign in to comment.