File tree 3 files changed +5
-1
lines changed
Assets/Thirdweb/Core/Scripts
3 files changed +5
-1
lines changed Original file line number Diff line number Diff line change @@ -55,6 +55,8 @@ public async Task<NFT> Get(string tokenId)
55
55
new TokenERC1155Contract . UriFunction ( ) { TokenId = BigInteger . Parse ( tokenId ) }
56
56
) ;
57
57
58
+ tokenURI . ReturnValue1 = tokenURI . ReturnValue1 . Contains ( "0x{id}" ) ? tokenURI . ReturnValue1 . Replace ( "0x{id}" , tokenId ) : tokenURI . ReturnValue1 ;
59
+
58
60
NFT nft = new NFT ( ) ;
59
61
nft . owner = "" ;
60
62
nft . type = "ERC1155" ;
Original file line number Diff line number Diff line change @@ -55,6 +55,8 @@ public async Task<NFT> Get(string tokenId)
55
55
new TokenERC721Contract . TokenURIFunction ( ) { TokenId = BigInteger . Parse ( tokenId ) }
56
56
) ;
57
57
58
+ tokenURI . ReturnValue1 = tokenURI . ReturnValue1 . Contains ( "0x{id}" ) ? tokenURI . ReturnValue1 . Replace ( "0x{id}" , tokenId ) : tokenURI . ReturnValue1 ;
59
+
58
60
NFT nft = new NFT ( ) ;
59
61
nft . owner = await OwnerOf ( tokenId ) ;
60
62
nft . type = "ERC721" ;
Original file line number Diff line number Diff line change @@ -87,7 +87,7 @@ public async Task<T> DownloadText<T>(string textURI)
87
87
await req . SendWebRequest ( ) ;
88
88
if ( req . result != UnityWebRequest . Result . Success )
89
89
{
90
- Debug . LogWarning ( $ "Unable to fetch text uri { textURI } data!") ;
90
+ Debug . LogWarning ( $ "Unable to fetch text uri { textURI } data! { req . error } ") ;
91
91
return default ( T ) ;
92
92
}
93
93
string json = req . downloadHandler . text ;
You can’t perform that action at this time.
0 commit comments