Closed code423n4 closed 2 years ago
Should also remove balanceOf in _burn
Override _burn in PuttyNft.sol
_burn
function _burn(uint256 id) internal virtual { address owner = _ownerOf[id]; require(owner != address(0), "NOT_MINTED"); delete _ownerOf[id]; delete getApproved[id]; emit Transfer(owner, address(0), id); }
Not a gas optimization.
Does not override _burn to delete remove balanceOf modifications
Should also remove balanceOf in _burn
Recommendation
Override
_burn
in PuttyNft.sol