@@ -1953,13 +1953,12 @@ public static async Task<VerifyResult> TokenERC20_VerifyMintSignature(this Third
1953
1953
/// <param name="contract">The contract to interact with.</param>
1954
1954
/// <param name="wallet">The wallet to use for the transaction.</param>
1955
1955
/// <param name="receiverAddress">The address of the receiver.</param>
1956
- /// <param name="tokenId">The ID of the token.</param>
1957
1956
/// <param name="uri">The URI of the token metadata.</param>
1958
1957
/// <returns>A task representing the asynchronous operation, with a ThirdwebTransactionReceipt result.</returns>
1959
1958
/// <exception cref="ArgumentNullException">Thrown when the contract or wallet is null.</exception>
1960
1959
/// <exception cref="ArgumentException">Thrown when the receiver address or URI is null or empty.</exception>
1961
1960
/// <exception cref="ArgumentOutOfRangeException">Thrown when the token ID is less than 0.</exception>
1962
- public static async Task < ThirdwebTransactionReceipt > TokenERC721_MintTo ( this ThirdwebContract contract , IThirdwebWallet wallet , string receiverAddress , BigInteger tokenId , string uri )
1961
+ public static async Task < ThirdwebTransactionReceipt > TokenERC721_MintTo ( this ThirdwebContract contract , IThirdwebWallet wallet , string receiverAddress , string uri )
1963
1962
{
1964
1963
if ( contract == null )
1965
1964
{
@@ -1976,12 +1975,7 @@ public static async Task<ThirdwebTransactionReceipt> TokenERC721_MintTo(this Thi
1976
1975
throw new ArgumentException ( "Receiver address must be provided" ) ;
1977
1976
}
1978
1977
1979
- if ( tokenId < 0 )
1980
- {
1981
- throw new ArgumentOutOfRangeException ( nameof ( tokenId ) , "Token ID must be equal or greater than 0" ) ;
1982
- }
1983
-
1984
- return uri == null ? throw new ArgumentException ( "URI must be provided" ) : await ThirdwebContract . Write ( wallet , contract , "mintTo" , 0 , receiverAddress , tokenId , uri ) ;
1978
+ return uri == null ? throw new ArgumentException ( "URI must be provided" ) : await ThirdwebContract . Write ( wallet , contract , "mintTo" , 0 , receiverAddress , uri ) ;
1985
1979
}
1986
1980
1987
1981
/// <summary>
@@ -1990,13 +1984,12 @@ public static async Task<ThirdwebTransactionReceipt> TokenERC721_MintTo(this Thi
1990
1984
/// <param name="contract">The contract to interact with.</param>
1991
1985
/// <param name="wallet">The wallet to use for the transaction.</param>
1992
1986
/// <param name="receiverAddress">The address of the receiver.</param>
1993
- /// <param name="tokenId">The ID of the token.</param>
1994
1987
/// <param name="metadata">The metadata of the token.</param>
1995
1988
/// <returns>A task representing the asynchronous operation, with a ThirdwebTransactionReceipt result.</returns>
1996
1989
/// <exception cref="ArgumentNullException">Thrown when the contract or wallet is null.</exception>
1997
1990
/// <exception cref="ArgumentException">Thrown when the receiver address is null or empty.</exception>
1998
1991
/// <exception cref="ArgumentOutOfRangeException">Thrown when the token ID is less than 0.</exception>
1999
- public static async Task < ThirdwebTransactionReceipt > TokenERC721_MintTo ( this ThirdwebContract contract , IThirdwebWallet wallet , string receiverAddress , BigInteger tokenId , NFTMetadata metadata )
1992
+ public static async Task < ThirdwebTransactionReceipt > TokenERC721_MintTo ( this ThirdwebContract contract , IThirdwebWallet wallet , string receiverAddress , NFTMetadata metadata )
2000
1993
{
2001
1994
if ( contract == null )
2002
1995
{
@@ -2013,18 +2006,13 @@ public static async Task<ThirdwebTransactionReceipt> TokenERC721_MintTo(this Thi
2013
2006
throw new ArgumentException ( "Receiver address must be provided" ) ;
2014
2007
}
2015
2008
2016
- if ( tokenId < 0 )
2017
- {
2018
- throw new ArgumentOutOfRangeException ( nameof ( tokenId ) , "Token ID must be equal or greater than 0" ) ;
2019
- }
2020
-
2021
2009
var json = JsonConvert . SerializeObject ( metadata ) ;
2022
2010
2023
2011
var jsonBytes = System . Text . Encoding . UTF8 . GetBytes ( json ) ;
2024
2012
2025
2013
var ipfsResult = await ThirdwebStorage . UploadRaw ( contract . Client , jsonBytes ) ;
2026
2014
2027
- return await ThirdwebContract . Write ( wallet , contract , "mintTo" , 0 , receiverAddress , tokenId , $ "ipfs://{ ipfsResult . IpfsHash } ") ;
2015
+ return await ThirdwebContract . Write ( wallet , contract , "mintTo" , 0 , receiverAddress , $ "ipfs://{ ipfsResult . IpfsHash } ") ;
2028
2016
}
2029
2017
2030
2018
/// <summary>
0 commit comments