Thanks to visit codestin.com
Credit goes to github.com

Skip to content
This repository was archived by the owner on May 3, 2024. It is now read-only.

Commit c04ed58

Browse files
authored
Require zero address in payload (#113)
1 parent b9c3aa1 commit c04ed58

File tree

2 files changed

+5
-6
lines changed

2 files changed

+5
-6
lines changed

tests/test_signature_mint_721.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -119,7 +119,6 @@ def test_claiming(
119119
assert nft_collection.get(tx[0].id).metadata.name == "OUCH VOUCH"
120120
assert nft_collection.balance_of(accounts[0].address) == 10
121121

122-
123122
@pytest.mark.usefixtures("sdk", "primary_account", "secondary_account")
124123
def test_custom_token(
125124
sdk: ThirdwebSDK,

thirdweb/types/contracts/signature.py

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99

1010
@dataclass
1111
class BaseSignaturePayloadInput:
12-
to: str = ZERO_ADDRESS
12+
to: str
1313
price: Price = 0
1414
currency_address: str = NATIVE_TOKEN_ADDRESS
1515
mint_start_time: int = int(time())
@@ -34,10 +34,10 @@ class Signature20PayloadOutput(Signature20PayloadInput):
3434

3535
@dataclass
3636
class Signature721PayloadInput:
37+
to: str
3738
metadata: NFTMetadataInput
3839
royalty_recipient: str = ZERO_ADDRESS
3940
royalty_bps: int = 0
40-
to: str = ZERO_ADDRESS
4141
price: Price = 0
4242
currency_address: str = NATIVE_TOKEN_ADDRESS
4343
mint_start_time: int = int(time())
@@ -52,11 +52,11 @@ def set_uid(self, uid: str) -> "Signature721PayloadInput":
5252

5353
@dataclass
5454
class Signature721PayloadOutput:
55+
to: str
5556
metadata: NFTMetadataInput
5657
royalty_recipient: str = ZERO_ADDRESS
5758
royalty_bps: int = 0
5859
uri: str = ""
59-
to: str = ZERO_ADDRESS
6060
price: Price = 0
6161
currency_address: str = NATIVE_TOKEN_ADDRESS
6262
mint_start_time: int = int(time())
@@ -71,12 +71,12 @@ def set_uid(self, uid: str) -> "Signature721PayloadOutput":
7171

7272
@dataclass
7373
class Signature1155PayloadInput:
74+
to: str
7475
metadata: NFTMetadataInput
7576
token_id: int
7677
quantity: int
7778
royalty_recipient: str = ZERO_ADDRESS
7879
royalty_bps: int = 0
79-
to: str = ZERO_ADDRESS
8080
price: Price = 0
8181
currency_address: str = NATIVE_TOKEN_ADDRESS
8282
mint_start_time: int = int(time())
@@ -91,13 +91,13 @@ def set_uid(self, uid: str) -> "Signature1155PayloadInput":
9191

9292
@dataclass
9393
class Signature1155PayloadOutput:
94+
to: str
9495
metadata: NFTMetadataInput
9596
royalty_bps: int
9697
royalty_recipient: str
9798
uri: str
9899
token_id: int
99100
quantity: int
100-
to: str = ZERO_ADDRESS
101101
price: Price = 0
102102
currency_address: str = NATIVE_TOKEN_ADDRESS
103103
mint_start_time: int = int(time())

0 commit comments

Comments
 (0)