Skip to content

Commit 9094be4

Browse files
committed
ERC1155: Throw when trying to mint to zero address
1 parent 4a28cbf commit 9094be4

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

erc1155/contracts/erc1155.vy

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -236,6 +236,7 @@ def mint(
236236
_supply: uint256,
237237
_data: bytes[256]=""
238238
) -> uint256:
239+
assert _to != ZERO_ADDRESS
239240
self._balanceOf[msg.sender][self.tokensIdCount] = _supply
240241
self.tokensIdCount += 1
241242
log.TransferSingle(msg.sender, ZERO_ADDRESS, _to, self.tokensIdCount, _supply)

0 commit comments

Comments
 (0)