diff --git a/contracts/NonFungibleToken.cdc b/contracts/NonFungibleToken.cdc index 6466d8c..6229b3d 100644 --- a/contracts/NonFungibleToken.cdc +++ b/contracts/NonFungibleToken.cdc @@ -169,10 +169,18 @@ access(all) contract interface NonFungibleToken: ViewResolver { access(all) view fun isSupportedNFTType(type: Type): Bool } + /// Kept for backwards-compatibility reasons + access(all) resource interface CollectionPublic { + access(all) fun deposit(token: @{NFT}) + access(all) view fun getLength(): Int + access(all) view fun getIDs(): [UInt64] + access(all) view fun borrowNFT(_ id: UInt64): &{NFT}? + } + /// Requirement for the concrete resource type /// to be declared in the implementing contract /// - access(all) resource interface Collection: Provider, Receiver { + access(all) resource interface Collection: Provider, Receiver, CollectionPublic { /// deposit takes a NFT as an argument and stores it in the collection /// @param token: The NFT to deposit into the collection diff --git a/lib/go/contracts/contracts_test.go b/lib/go/contracts/contracts_test.go index 0715dba..7921e80 100644 --- a/lib/go/contracts/contracts_test.go +++ b/lib/go/contracts/contracts_test.go @@ -24,15 +24,13 @@ func TestExampleNFTContract(t *testing.T) { addressA := addresses.New() addressB := addresses.New() addressC := addresses.New() - addressD := addresses.New() - contract := contracts.ExampleNFT(addressA, addressB, addressC, addressD) + contract := contracts.ExampleNFT(addressA, addressB, addressC) assert.NotNil(t, contract) assert.Contains(t, string(contract), addressA.String()) assert.Contains(t, string(contract), addressB.String()) assert.Contains(t, string(contract), addressC.String()) - assert.Contains(t, string(contract), addressD.String()) } func TestMetadataViewsContract(t *testing.T) { diff --git a/lib/go/contracts/internal/assets/assets.go b/lib/go/contracts/internal/assets/assets.go index c6ce26e..9aca497 100644 --- a/lib/go/contracts/internal/assets/assets.go +++ b/lib/go/contracts/internal/assets/assets.go @@ -3,7 +3,7 @@ // BasicNFT.cdc (5.925kB) // ExampleNFT.cdc (13.904kB) // MetadataViews.cdc (25.358kB) -// NonFungibleToken.cdc (10.396kB) +// NonFungibleToken.cdc (10.727kB) // UniversalCollection.cdc (4.31kB) // ViewResolver.cdc (2.718kB) @@ -135,7 +135,7 @@ func metadataviewsCdc() (*asset, error) { return a, nil } -var _nonfungibletokenCdc = "\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\xbc\x5a\x51\x6f\x23\xb7\x11\x7e\xdf\x5f\x31\x75\x80\xda\x0e\x74\x72\x1f\x8a\x3e\x18\x08\x2e\x97\x38\x2e\x04\x14\x4e\x71\xd1\x25\x0f\x45\x11\x51\xbb\x23\x89\x3d\x2e\xb9\x47\x72\xa5\xa8\x8e\xff\x7b\x31\x43\x72\x97\xbb\x5a\xf9\xec\xa4\xad\x1e\x92\xd3\x6a\x39\x1c\xce\x7c\x33\xf3\xcd\xd0\x37\x5f\x7e\x59\x14\x5f\x7c\x01\xcb\x1d\xc2\xbd\x32\x07\x78\x30\xfa\xcd\x7d\xab\xb7\x72\xad\x10\x96\xe6\x23\x6a\x70\x5e\xe8\x4a\xd8\x8a\x5f\x5c\x3d\x18\x9d\x7e\xe7\x9f\x57\x50\x1a\xed\xad\x28\x7d\x51\x90\x14\xa9\x3d\xda\x8d\x28\x11\xfc\x4e\x78\x10\x4a\x4d\xc9\x4c\x6b\x1c\xb8\x9d\x69\x55\x45\x0f\x36\xc6\xd6\xe0\xcd\xbc\x58\x6c\x40\x40\xeb\xd0\xc2\x41\x68\xef\xc0\x1b\xa8\xb0\x51\xe6\x08\x02\x34\x1e\xe0\xe1\x7e\xd9\x09\x98\x81\xdf\xa1\xb4\xdd\xf7\x24\x4f\xd6\x8d\xc2\x1a\xb5\x67\xa5\xfc\xb1\x41\x07\x15\x6e\xa4\xc6\x0a\x76\x68\x31\x1e\xe6\x7e\xb9\x02\x8b\xce\xb4\xb6\xcc\x54\x0f\x27\x29\x8d\xc5\xfe\x47\x12\x11\x8e\x64\xb1\xb1\xe8\x90\x34\x13\x9a\x95\x91\x9a\xb4\x00\x57\x0b\xeb\x3b\x4d\xe6\x61\x8b\x6f\x8d\x52\x58\x7a\x69\xf4\x0a\xde\x9f\xd9\xa9\xdf\x84\xe4\x3b\x6f\x2c\xba\x68\x82\x4b\x17\x8f\x9b\xa4\xcc\x8b\x85\x07\xa9\x4b\xd5\x56\xfc\xd2\x06\x0f\xb0\x69\x35\xff\xc6\xa6\x12\x8a\xfc\x48\xfa\x98\x83\x46\x4b\x8f\x50\x38\xa9\x8e\x45\x6d\xf6\x08\x9e\xec\xef\x48\x65\xa1\x2b\x30\xad\x07\xb3\xe1\xb7\xf3\x2d\x58\xf3\xbf\x5b\xb3\x97\x15\xda\x15\xbf\xb9\x7a\x8f\x25\xca\x3d\x7d\x3d\x35\x98\xe3\x73\xb8\xfc\x09\x54\x58\x2a\x61\x31\x53\xee\x20\xfd\x0e\x9c\xa9\x11\x1a\x8b\x2c\xb4\x31\x8e\x0d\x56\x49\x7e\xa3\x88\xf6\xfd\xd4\x4a\x8b\xac\x54\x6f\x3d\x3a\xc7\xc6\xf0\xd9\x4a\xb4\x5e\x48\x0d\x5a\xd4\x52\x6f\x59\xd0\x1a\x77\x62\x2f\x8d\xed\xc0\xea\xe6\xac\xd2\x11\x48\x05\x87\x8d\xb0\xc2\x23\xac\xb1\x14\x2d\xa9\xe9\x61\x2b\xf7\xac\xe4\x1e\x95\x69\xd0\x3a\xde\x4e\xac\xa5\x92\xfe\x18\x10\x47\x60\xe9\xb5\x0f\xba\x95\x42\x93\x5b\x40\xe8\x63\x86\x88\x0e\x6c\x2c\xc5\x0d\x0d\xf3\xcd\x11\x5a\x47\x7a\x26\xb3\x39\xd6\xb8\x7f\x65\xc6\x8e\x76\xe4\x07\x72\xf5\x10\x45\x8e\xb7\x74\xa8\xab\x82\x56\xd9\xe0\x84\xe4\xc5\x06\xd1\xbe\xf1\xe6\x0d\xfd\x7f\xc6\xf6\x25\x87\x92\x29\xf4\x96\x0e\xc1\x9b\x50\x54\xb0\xe9\x05\x94\x48\x52\x15\x28\xac\xb6\x68\x8b\x13\xc0\x2e\x0d\x6f\x95\x70\x4d\x68\xd2\xc6\xef\xd0\xb2\x8a\xb3\x2e\x2c\x39\xc4\x1c\x1d\xfb\xc8\xa2\x2b\x2b\x02\xe4\x1e\xee\x97\xc5\xc6\x9a\x3a\x46\x65\xef\x3e\x8e\x53\x0d\x25\xe5\x03\x7a\xb1\xc2\xc6\x38\xe9\x3b\xfb\x82\xd1\x83\xbd\x2e\x5d\x31\xf4\x7d\x69\xc8\xc8\x3e\xc0\xc2\x5b\xa1\xdd\x06\xed\xbc\x28\xbe\xbc\x29\x0a\x59\x37\xc6\x7a\xf8\x51\xe2\x81\x42\x4c\xed\xd1\x02\x6b\x71\x91\x3f\xba\x28\x8a\x9b\x9b\x1b\x4e\x75\x35\xc1\x27\x4f\x23\x73\xf8\x9e\xb7\xce\x9f\x11\x60\x95\xe2\x35\x71\x03\xf6\x5b\xf2\x35\x2b\x32\xc0\x7b\xc8\x2e\x9c\x0c\xa4\xeb\xd3\xe2\xcd\xcd\x4d\x21\xca\x12\x9d\xbb\x12\x4a\x5d\xf7\xa9\xaa\x4f\x95\xe3\xa4\x7a\x3b\x3c\xcb\x63\x51\x00\x00\x90\x26\xef\x34\xa0\xf6\xd2\x47\x1d\x36\xc6\x86\x80\x67\x87\xef\xb0\xf3\x86\x50\x1c\xd7\x01\x26\x6c\x0b\x01\x3f\x8a\x56\x79\x96\x94\xab\x93\x8b\xfb\x29\xae\x7e\xd9\x7e\x6d\x53\x09\x1f\xe1\x1c\xfe\x0d\xb8\xe7\x28\xe0\xd7\xd8\xc2\xcf\x6e\xf7\x81\x17\xf5\x9b\x8d\x77\x8a\x09\x8c\x42\x6c\x6b\xb9\x14\x24\x05\x79\xcf\xb8\xfc\xb9\x1d\xbe\x27\x09\xfd\x06\xdf\xed\x83\xe3\x84\x3f\xad\x40\x58\x4b\x0f\x07\x02\x29\xd9\xb1\x46\x2f\x2a\xe1\x05\x59\x31\x65\x79\x17\x4f\x59\x75\xf2\x16\x21\x23\x18\xad\x8e\xb0\x46\x16\xe1\xb1\x82\xf5\x91\x81\x9e\x7c\xb2\xa2\xe7\x0f\xf7\xcb\xa0\x6f\xb5\xea\x40\xdf\xc9\x09\xe1\xa9\x61\xc5\xaf\x88\xb5\xc2\x55\x3a\x06\xc5\xfc\x06\x2d\x6a\x2a\x0f\x26\x05\x59\x38\xc3\x41\x9c\xaa\x44\xf0\xce\x2d\xd0\xd8\xe8\x13\xd7\x88\xba\xa6\x3c\xc3\x68\xe8\xf5\x93\xf1\x49\x1f\x7b\xee\x32\x2b\x06\xae\x93\x9c\x92\x27\x9f\xb6\x34\x55\x00\x1b\x15\x92\xec\x75\x30\xd1\x61\x3b\x41\x5b\x62\x29\x85\xea\x8f\x12\xdc\xd4\x49\x8c\xe7\xc9\x36\x23\xbb\xef\x4c\x15\x42\x8f\x4c\x4a\xb6\xa0\xf7\xb6\x18\x02\xee\xd4\x2a\x9d\xb4\xa1\x09\xd8\xd3\xb5\xf8\x88\x8e\xb2\xbd\x33\x41\x2b\xbf\x93\xb6\x7a\xd3\x08\xeb\x8f\x20\x75\x85\xbf\x90\x41\xc8\x85\xb5\xd1\xd2\xb3\xee\x09\xc4\x9d\x38\x82\xda\xa7\x16\xed\x91\x7f\x8c\xf6\xee\x01\x92\xd2\x5d\x40\xeb\xd0\x76\xf3\x24\xe4\x14\xa4\xfb\x3e\x00\xaa\x2b\x2a\x25\xb7\xf0\x83\xb7\x52\x6f\x67\x20\xab\x5b\xf8\xb0\xd0\xfe\x2f\x7f\x9e\x41\xdb\xe6\xdf\x78\x8b\x5b\x78\x57\x55\x16\x9d\x7b\x7b\x9d\x8b\x4d\x80\xbe\x86\xbd\x0c\x9c\x00\x86\xb8\xbb\xfa\x19\xf4\xc6\xbf\xc7\xcd\x2d\x88\xd6\xef\xae\xc2\x63\xf8\x35\x04\xc9\x35\xfc\xf1\x71\x9c\x86\xe6\x0f\xf7\xcb\xa7\xb0\xc9\x23\xff\x97\x3e\x1c\x27\x43\xc5\x83\xd8\xf9\x16\xfd\xf2\xd8\xe0\xd5\xf5\x5c\x56\xe4\xa7\x8d\xa4\x9a\x41\xfa\xc7\x17\x64\x95\x0e\x14\x1f\xd0\x97\xee\x54\xf1\x19\x7f\x7b\x3b\x17\xe1\x8c\x61\xf7\xa7\x62\x32\x86\xa5\xeb\x42\x8e\x03\x57\x84\x84\x47\xcf\x53\x1e\xd4\xb3\x6e\xa1\xd4\x95\x2c\x85\x4f\x51\x49\xaa\x93\x76\x41\xa5\x59\xc6\x98\x4e\x08\x51\xdc\x2d\x04\x5c\x27\x99\x3d\x3f\x1b\xc0\x84\x96\x7d\xf8\xb0\xb8\x4b\x22\x7a\xa6\x34\xb9\x16\x5a\xd7\x0a\xa5\x8e\x83\x08\x1a\x62\x86\xb3\xcc\x89\x3e\xd2\x81\x36\x3e\x90\x38\xf2\xbf\x69\xb5\xbf\x74\xcc\x1c\xc5\x16\x67\xb0\x22\xf1\xab\x2e\x88\x56\x5a\xaa\xd5\xe7\xb0\x98\x52\xab\x7e\x31\x1a\x69\x93\x1e\x8c\x33\x68\x22\x61\x24\x0b\xa4\xb7\xae\x27\x1d\x77\xce\x6b\x91\x15\x60\xc5\xd4\x63\xca\x28\xb0\x08\x5e\x44\xf7\xbb\x9c\x98\x6f\xf4\xbc\x0b\x73\xab\x9f\xae\xfd\xaf\xf9\x6a\xf6\x3a\x67\xdd\x25\x1d\x5e\xec\x2c\x6f\x72\x57\xf5\xfa\x9d\x71\xd6\x22\x74\x18\x15\xd7\xe1\xb5\x28\x3f\x1e\x88\x54\xbf\x21\x16\x26\xbc\x0c\x34\xf9\x44\xb7\xd3\xc6\x00\x16\x0f\xf7\xcb\x5b\xae\x58\x8f\x4f\xb9\xf4\x41\x93\x18\x8b\x9a\x83\xba\x0d\xfd\x40\x6c\x05\xcf\x1a\x61\x62\x23\xde\x27\x67\x4d\xf3\x31\x7d\x4a\x9b\xb7\x5a\x7e\x6a\x11\x16\x77\x7c\xb6\xc4\x5a\xd3\x1b\xf9\x36\x0a\x7d\x66\xd1\xa1\x94\xe9\x34\x24\x5a\x6f\x6a\xe1\x65\xc9\x61\x8d\x7b\xae\x1a\xb2\x46\x10\x99\xce\x04\x21\xe7\xad\x39\xc6\xb2\x9d\xd7\x2d\x6e\x2a\x24\x1b\x40\x24\xf8\xc8\xe4\x0b\x39\xe2\x26\x01\x0b\xce\x10\x32\x23\xcc\x34\x22\xbd\x29\xb8\x37\x15\x76\xdb\x72\x0f\x3c\x75\xb8\xb0\x38\xb5\xa4\x77\x49\xa3\xab\xfe\xc0\xf0\x15\x38\x54\x79\xda\x1e\x3e\xa7\x67\xd7\x43\xab\x94\x16\x85\xc7\xef\xea\xc6\x1f\x33\xfa\x1e\x9e\xb2\x4a\x48\x3f\x0d\xda\xba\x68\xc1\x54\xe8\xb9\xfb\x3d\xf1\x4a\x8a\x4e\x8b\xbe\xb5\x9a\x4b\x7a\x22\x0f\x42\x29\xb4\x59\x81\xc7\x63\xe0\x64\x07\x66\x6d\x6e\x20\xe2\xeb\xb0\x1e\xde\xf5\xaa\x8c\x13\x04\xb7\x5b\x51\x07\xe9\xce\x42\x83\xca\xeb\xe4\x61\xaf\xae\x6f\xe1\xeb\xc7\xfe\xfb\x53\x56\x3a\xe9\xc3\x2d\xef\xf0\x11\x7d\x2c\xba\x56\x79\x2a\xa1\x7f\x43\xbd\xf5\xbb\xab\x6b\xf8\xea\x2b\xf8\xd3\x2d\x5c\xf0\x28\x82\x77\xaa\x72\x65\x39\x54\x98\x73\x36\xfe\xf8\x87\x8b\x81\xc0\xa7\xa2\xff\xd7\xe0\xfc\x7f\x45\xef\x20\xb5\x60\x1c\x71\x89\x15\x85\x31\x43\x25\x2d\x96\x5e\x1d\xc9\x7a\xe7\x2c\x57\x49\x56\x40\xd8\x23\x73\x63\xa5\xc0\xb5\xeb\x87\xfb\xe5\x0f\xf0\x11\x8f\x81\xfc\x12\x88\x27\xad\xd6\x31\x93\x2d\xfa\x77\x7b\x21\x15\x79\xfd\x87\xb0\x9c\x0c\xf7\xb8\xe4\x6c\x16\x60\x36\xb6\x5c\xd4\xe0\xf1\xb9\xd3\x71\x9c\x65\x74\x39\x35\xb2\x83\x53\x9e\x1c\xee\x1b\x43\xf4\x3b\x06\x8b\xe3\x91\x81\x69\xf8\x90\x6a\x38\x51\x89\x4d\x71\xb9\x33\xc6\xe1\x40\xc4\xce\x1c\x08\x94\x09\x9f\xae\x5d\x07\xfb\x56\xd8\xa0\xae\x88\x73\x18\x0d\x07\x9e\x88\x0d\xf6\x89\x35\x73\x98\x08\xee\x8d\x05\xfc\x45\x50\xa7\x39\x03\xb9\x81\x15\x19\x74\xc5\x94\x5a\xc0\x5e\xa8\x16\x67\xb0\x6e\x3d\xac\x64\xb5\x82\xca\xa0\xd3\x97\x61\x10\xc6\x0a\x0e\x03\x52\xe8\xa8\x2e\x1c\x76\xb2\xdc\x05\x03\x6c\xa2\x45\x78\x82\x61\x92\x65\x25\xd7\x2e\xcb\x19\x4a\xc0\x45\x85\x1b\x6a\x18\x2f\x06\xf2\x16\x1b\x58\x07\x6b\xc5\x4a\x15\x1b\xfb\x1e\x4c\xdc\x1e\x84\x08\x12\xe0\xa4\xde\xaa\xa0\x16\x69\xf2\x2f\x02\x6d\xd8\x6d\x20\x95\x16\xce\x61\x49\x0e\xda\xa1\x6a\x5c\x8c\x6a\x07\x87\x9d\xa1\xad\xf4\xa5\x07\xd7\x5a\x0c\x16\xf4\x69\xae\xa3\x8c\xf9\x48\xa6\xa5\x3c\x9e\xcb\x1b\x22\xb7\x11\x56\xd4\x10\xea\x24\x05\x13\x61\x2c\x55\xf7\x0a\x9d\xb4\x58\x9d\xe4\x9a\xb8\x88\x72\x1e\x0f\x35\xab\xb4\x20\x22\x60\x6d\xac\x35\x87\xf3\x7b\x76\xd1\xe2\xbc\x6d\x4b\xdf\xf2\x24\x31\x8e\x0d\x13\x01\xb5\xf8\xa9\x45\x47\x61\x4d\x61\x31\x3f\x9b\x66\xb6\xe8\x43\x88\xc4\x5a\xbf\x8c\x9c\xa7\xab\xda\x70\x7b\x8e\xbb\xbf\x9d\x0e\x21\x2d\x55\x31\xcc\x15\xd3\xb5\xd9\x40\x8d\x95\xa4\x26\xa1\x1f\x2b\x74\xd3\x84\x54\xcf\x72\x16\xdb\xa7\xbd\xd7\x94\xee\x34\x68\x1c\x16\x6a\xf8\x09\x63\x4f\x9e\x7a\xfe\x34\x5c\x48\x0d\x57\xe2\x9b\x99\xa8\xd4\xa3\x12\x87\xa0\x3c\xa5\xb7\xdd\xf2\x5c\x74\x94\x14\x91\x25\x78\x58\xb3\x09\x53\x3a\x6f\x62\x65\x54\xd2\x79\xa4\x8e\x2e\xfd\xae\xa2\xc0\x34\xba\x8a\x6d\xe2\xc0\xf1\x9d\xae\x16\x6b\xb3\xc7\x6e\x42\xdc\xe9\x9c\x65\x70\xaa\x67\xe1\xa5\x71\x35\x1b\x46\x9c\xe7\x10\xe7\xea\xce\x0d\xf5\xe6\x48\xbc\x99\xbb\x75\x5a\xb2\xb8\xa3\x78\x0d\x94\xd5\xd2\x5b\x53\x40\x4e\x7a\x11\xd7\x9b\x04\x74\xa7\xf8\x84\xa6\x63\x64\x76\x43\x98\xae\x75\x24\x98\x26\x09\x57\xf9\x5e\x11\xa1\x54\x12\x09\x8f\xaf\xaa\x85\xb2\xa2\x12\x98\x4b\xe3\x5a\xd8\x53\xf3\xbe\x9b\x0a\x0d\x44\x2a\x89\x3c\x8b\x17\x44\xba\xdc\x28\xd0\x16\x77\x17\x27\xbb\x31\xc6\xc6\xcd\x4f\x5f\x8e\xcf\x74\xb4\x9d\x8e\x89\x1a\xc5\x07\xa1\x0d\x09\x9d\x11\x93\xa4\x61\x3b\x3b\x6e\x92\x32\x1e\x95\xeb\xf4\xf4\xca\xf0\x8c\x90\x74\x09\x46\xbf\x2d\x0e\xd3\x84\x7f\x4c\x98\x13\xe0\x3d\x4f\x53\x22\xa2\x87\x0c\x93\xc1\x2c\xaa\x2a\xc7\xf2\xb7\xa7\x00\xca\xf3\x71\x98\x73\x2e\x7b\x08\xc6\x6d\xce\xe6\xc1\xf8\xfb\x55\x5c\x19\x10\x35\xe2\x9f\x9c\x2b\x9b\xc6\x58\x8f\xd5\xc3\xfd\x72\xc9\xf7\x3e\xa9\x28\x0b\x8e\xe9\x34\x67\x0f\x77\x42\x3d\x33\xb0\xe9\xf4\xb4\x6f\xe3\x5f\x46\x7f\x82\x90\x5a\x34\x4d\xe8\x59\xd7\xc6\x28\x14\x7c\xbf\xd2\x0d\x1b\xb8\xac\xca\xa1\xbc\x1e\xea\xa5\xa4\x2e\x01\x5c\xd0\x9a\xec\xf7\x59\xe6\x74\x72\xc2\x8c\x3a\x7d\x63\x8c\x1a\xd1\xa2\xf7\xf1\xf8\x29\x69\x84\x2c\xc1\x2e\xda\xca\x3d\xea\xd8\x73\xb8\x78\xf0\x48\xe1\xa6\x33\x00\x8f\x84\x27\x39\x73\x58\xdc\x5f\x8c\xc4\xa9\x6a\x56\xf1\xc1\xdb\x16\x49\x76\x24\x16\xe7\xab\xf4\x3b\xdd\x79\xe8\x8c\x17\xa2\x9d\x27\xcc\xdc\xfb\x91\xb4\x8a\xf6\x1d\xd7\xfa\x17\x30\x54\xe9\xc6\x66\xce\xca\xef\x75\x30\xf4\x38\x36\xdf\x87\x9b\xab\x6e\x7e\x1d\x8c\xa8\x4b\x8b\x7e\x74\x93\x98\x8f\x40\xd7\x98\xee\xca\xba\x0e\xaf\xbb\x64\xa0\x83\x75\x17\x09\xaf\x08\xe5\x3e\xf6\x6e\xbb\xf2\x3a\x7b\x69\x80\x9f\x8b\xef\x78\x31\x29\x7d\x52\xf3\x0c\x40\x3e\x17\xe1\xa4\xe7\x78\xf2\xfb\x8a\xa8\x9f\x1c\x52\x8e\x2b\x8b\xc5\x89\xc2\x92\x91\x8a\xfc\x0e\x2a\xd4\xfb\x78\xa6\xc1\x85\x6d\x7f\x4f\x3b\x21\x2a\x71\x8d\xf3\xab\x38\xa8\x54\x4d\x55\x4e\xa8\x83\x38\x86\x72\xb4\x91\xd4\x57\x54\xe8\xbc\xd4\x62\x70\xf6\x4c\x78\x7f\x79\x43\x96\xef\x34\xad\xa5\x73\x3c\x27\x0f\x43\xfc\xd6\x79\x53\x77\x88\x27\x9a\x42\x31\xb7\xc6\x9e\xcf\x4c\xc9\x26\x89\x3b\x61\xab\x40\xfd\x09\xa0\x32\xf4\xde\x23\xe2\x33\x5d\x2a\xc7\xa3\x27\x56\xf3\x99\x4a\x19\x7e\xef\x0b\x65\xf8\x1e\xc7\x75\xe6\x4c\x95\x1c\xcf\xa7\x5e\x50\x27\x4f\x1b\x5d\xbe\xd1\xad\x4d\xab\x53\xce\x0f\x53\xb7\x3e\xcc\xce\xe1\x37\xa5\x19\xcd\xae\xdc\x32\xc3\x1c\xcc\x8e\x9d\xfc\x37\x9e\x0e\x08\x3f\x9b\xb8\x53\x6b\x7f\x4b\x55\x7c\xaa\x33\xef\x0a\x54\xea\xd1\x17\x77\xee\xe5\xca\x0a\x6b\xc5\x31\x95\xb7\xe7\x57\x9e\xd3\x70\x71\xc7\xc5\xe4\x1f\x81\xb7\xfd\x13\x8a\x51\x9f\x4c\x5d\x8f\x3b\xd3\x64\xbf\xc8\xb6\x8b\x9e\x75\xf2\xa5\x17\x5b\x93\x59\xad\x64\x7e\x96\x8d\x4b\x87\x52\x66\xa3\x86\xb1\xbf\x9a\x4f\xa5\x26\x1a\x82\xbb\x52\xc6\x38\xc9\x69\x84\x96\xe5\xfc\x73\xcd\x61\xea\xf3\x52\x89\xd0\x1b\x4f\x14\xf9\x44\x89\xac\x59\x4e\x36\x28\x91\x52\xfd\xfc\x9c\x4f\xba\x39\xc2\xd4\x2d\xde\xf3\xee\x08\x3d\x26\xf5\x7d\x3f\xe7\xdd\xde\x8b\x9b\xbd\x33\xec\xfa\x2a\x30\x55\xe2\xd6\x5a\xaa\x6b\xf8\xf5\xd7\xf4\xe8\x6d\xa4\xdc\xb2\xba\xbe\x85\x93\x75\xf4\xb9\xf8\x56\x68\xb2\x6a\x50\x8d\xbd\xd8\x9d\x2b\x58\x30\xbf\xfb\x20\x1b\x0c\xee\x2f\xbb\x3e\xa6\x16\xbe\xdc\xa5\xee\xa5\xbb\xca\xec\x70\xf0\xc2\x69\xd6\xeb\x87\x8d\x51\x35\x6e\x0e\x4e\xd8\xc5\x73\xf3\xc5\x57\x4c\x11\xcf\xee\xf1\xff\x19\x1f\x86\x2c\x4c\x6e\xe4\x9c\xd9\x3d\x39\x3f\x49\xec\xbc\xb2\x13\x7b\x1c\xea\x1e\x3a\x28\xfe\x63\x86\xf4\xfa\x69\x03\xf5\x3f\x1b\x5d\xc2\x90\x5d\xbd\xde\xdd\x89\x83\xf5\x09\x66\xc0\xfd\x7e\xe7\x50\x39\xcb\x1f\x7a\xe3\x97\xdd\x7c\x29\x4f\x22\xa3\x09\xdb\xe0\xa6\xbc\x4b\x1b\xcf\xa5\xf1\x65\xde\xa5\x9c\x21\x86\xf1\x4f\x4f\xe2\x6d\xf3\xcb\x60\xd6\x6b\x1c\xe8\xec\x04\xaf\x9a\x06\xe1\x04\x00\x7b\x00\x70\xf9\x98\x2b\x86\xc1\x6f\x04\x41\x72\xfb\x53\xf1\x9f\x00\x00\x00\xff\xff\x42\x9e\x6c\x8a\x9c\x28\x00\x00" +var _nonfungibletokenCdc = "\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\xbc\x5a\x4f\x8f\xe3\x36\xb2\xbf\xeb\x53\xd4\xeb\x00\x6f\xba\x03\x8f\xfb\x1d\x1e\xf6\xd0\x40\x30\x99\xa4\xd3\x0b\x63\x17\x9d\x60\xe2\x49\x0e\x8b\x45\x4c\x4b\x65\x9b\x3b\x14\xa9\x21\x29\x3b\xde\x4e\x7f\xf7\x45\x15\x49\x89\x92\xe5\xfe\x93\xec\x6e\x1f\x92\xb1\x2c\x16\x8b\x55\xbf\xaa\xfa\x55\xd1\xd7\x5f\x7e\x59\x14\x5f\x7c\x01\xcb\x1d\xc2\x9d\x32\x07\xb8\x37\xfa\xed\x5d\xab\xb7\x72\xad\x10\x96\xe6\x13\x6a\x70\x5e\xe8\x4a\xd8\x8a\x5f\x5c\xdd\x1b\x9d\xbe\xe7\xaf\x57\x50\x1a\xed\xad\x28\x7d\x51\x90\x14\xa9\x3d\xda\x8d\x28\x11\xfc\x4e\x78\x10\x4a\x4d\xc9\x4c\x6b\x1c\xb8\x9d\x69\x55\x45\x0f\x36\xc6\xd6\xe0\xcd\xbc\x58\x6c\x40\x40\xeb\xd0\xc2\x41\x68\xef\xc0\x1b\xa8\xb0\x51\xe6\x08\x02\x34\x1e\xe0\xfe\x6e\xd9\x09\x98\x81\xdf\xa1\xb4\xdd\xe7\x24\x4f\xd6\x8d\xc2\x1a\xb5\x67\xa5\xfc\xb1\x41\x07\x15\x6e\xa4\xc6\x0a\x76\x68\x31\x1e\xe6\x6e\xb9\x02\x8b\xce\xb4\xb6\xcc\x54\x0f\x27\x29\x8d\xc5\xfe\x4b\x12\x11\x8e\x64\xb1\xb1\xe8\x90\x34\x13\x9a\x95\x91\x9a\xb4\x00\x57\x0b\xeb\x3b\x4d\xe6\x61\x8b\x6f\x8d\x52\x58\x7a\x69\xf4\x0a\x3e\x9c\xd9\xa9\xdf\x84\xe4\x3b\x6f\x2c\xba\x68\x82\x37\x2e\x1e\x37\x49\x99\x17\x0b\x0f\x52\x97\xaa\xad\xf8\xa5\x0d\x1e\x60\xd3\x6a\xfe\x8e\x4d\x25\x14\xf9\x91\xf4\x31\x07\x8d\x96\x1e\xa1\x70\x52\x1d\x8b\xda\xec\x11\x3c\xd9\xdf\x91\xca\x42\x57\x60\x5a\x0f\x66\xc3\x6f\xe7\x5b\xb0\xe6\x3f\x58\xb3\x97\x15\xda\x15\xbf\xb9\xfa\x80\x25\xca\x3d\x7d\x3c\x35\x98\xe3\x73\xb8\xfc\x09\x54\x58\x2a\x61\x31\x53\xee\x20\xfd\x0e\x9c\xa9\x11\x1a\x8b\x2c\xb4\x31\x8e\x0d\x56\x49\x7e\xa3\x88\xf6\xfd\xdc\x4a\x8b\xac\x54\x6f\x3d\x3a\xc7\xc6\xf0\xd9\x4a\xb4\x5e\x48\x0d\x5a\xd4\x52\x6f\x59\xd0\x1a\x77\x62\x2f\x8d\xed\xc0\xea\xe6\xac\xd2\x11\x48\x05\x87\x8d\xb0\xc2\x23\xac\xb1\x14\x2d\xa9\xe9\x61\x2b\xf7\xac\xe4\x1e\x95\x69\xd0\x3a\xde\x4e\xac\xa5\x92\xfe\x18\x10\x47\x60\xe9\xb5\x0f\xba\x95\x42\x93\x5b\x40\xe8\x63\x86\x88\x0e\x6c\x2c\xc5\x0d\x0d\xf3\xcd\x11\x5a\x47\x7a\x26\xb3\x39\xd6\xb8\x7f\x65\xc6\x8e\x76\xe4\x07\x72\xf5\x10\x45\x8e\xb7\x74\xa8\xab\x82\x56\xd9\xe0\x84\xe4\xc5\x06\xd1\xbe\xf5\xe6\x2d\xfd\x7f\xc6\xf6\x25\x87\x92\x29\xf4\x96\x0e\xc1\x9b\x50\x54\xb0\xe9\x05\x94\x48\x52\x15\x28\xac\xb6\x68\x8b\x13\xc0\x2e\x0d\x6f\x95\x70\x4d\x68\xd2\xc6\xef\xd0\xb2\x8a\xb3\x2e\x2c\x39\xc4\x1c\x1d\xfb\xc8\xa2\x2b\x2b\x02\xe4\xee\xef\x96\xc5\xc6\x9a\x3a\x46\x65\xef\x3e\x8e\x53\x0d\x25\xe5\x03\x7a\xb1\xc2\xc6\x38\xe9\x3b\xfb\x82\xd1\x83\xbd\xde\xb8\x62\xe8\xfb\xd2\x90\x91\x7d\x80\x85\xb7\x42\xbb\x0d\xda\x79\x51\x7c\x79\x5d\x14\xb2\x6e\x8c\xf5\xf0\x93\xc4\x03\x85\x98\xda\xa3\x05\xd6\xe2\x22\x7f\x74\x51\x14\xd7\xd7\xd7\x9c\xea\x6a\x82\x4f\x9e\x46\xe6\xf0\x3d\x6f\x9d\x3f\x23\xc0\x2a\xc5\x6b\xe2\x06\xec\xb7\xe4\x6b\x56\x64\x80\xf7\x90\x5d\x38\x19\x48\xd7\xa7\xc5\xeb\xeb\xeb\x42\x94\x25\x3a\x77\x29\x94\xba\xea\x53\x55\x9f\x2a\xc7\x49\xf5\x66\x78\x96\x87\xa2\x00\x00\x20\x4d\xde\x6b\x40\xed\xa5\x8f\x3a\x6c\x8c\x0d\x01\xcf\x0e\xdf\x61\xe7\x0d\xa1\x38\xae\x03\x4c\xd8\x16\x02\x7e\x12\xad\xf2\x2c\x29\x57\x27\x17\xf7\x73\x5c\xfd\xb2\xfd\xda\xa6\x12\x3e\xc2\x39\xfc\x1b\x70\xcf\x51\xc0\xaf\xb1\x85\x9f\xdc\xee\x23\x2f\xea\x37\x1b\xef\x14\x13\x18\x85\xd8\xd6\x72\x29\x48\x0a\xf2\x9e\x71\xf9\x53\x3b\x7c\x4f\x12\xfa\x0d\xbe\xdb\x07\xc7\x09\x7f\x5a\x81\xb0\x96\x1e\x0e\x04\x52\xb2\x63\x8d\x5e\x54\xc2\x0b\xb2\x62\xca\xf2\x2e\x9e\xb2\xea\xe4\x2d\x42\x46\x30\x5a\x1d\x61\x8d\x2c\xc2\x63\x05\xeb\x23\x03\x3d\xf9\x64\x45\xcf\xef\xef\x96\x41\xdf\x6a\xd5\x81\xbe\x93\x13\xc2\x53\xc3\x8a\x5f\x11\x6b\x85\xab\x74\x0c\x8a\xf9\x0d\x5a\xd4\x54\x1e\x4c\x0a\xb2\x70\x86\x83\x38\x55\x89\xe0\x9d\x5b\xa0\xb1\xd1\x27\xae\x11\x75\x4d\x79\x86\xd1\xd0\xeb\x27\xe3\x93\x3e\xf6\xdc\x9b\xac\x18\xb8\x4e\x72\x4a\x9e\x7c\xda\xd2\x54\x01\x6c\x54\x48\xb2\xd7\xc1\x44\x87\xed\x04\x6d\x89\xa5\x14\xaa\x3f\x4a\x70\x53\x27\x31\x9e\x27\xdb\x8c\xec\xbe\x33\x55\x08\x3d\x32\x29\xd9\x82\xde\xdb\x62\x08\xb8\x53\xab\x74\xd2\x86\x26\x60\x4f\xd7\xe2\x13\x3a\xca\xf6\xce\x04\xad\xfc\x4e\xda\xea\x6d\x23\xac\x3f\x82\xd4\x15\xfe\x4a\x06\x21\x17\xd6\x46\x4b\xcf\xba\x27\x10\x77\xe2\x08\x6a\x9f\x5b\xb4\x47\xfe\x32\xda\xbb\x07\x48\x4a\x77\x01\xad\x43\xdb\xcd\x93\x90\x53\x90\xee\xfb\x00\xa8\x2e\xa9\x94\xdc\xc0\x8f\xde\x4a\xbd\x9d\x81\xac\x6e\xe0\xe3\x42\xfb\x3f\xfd\xff\x0c\xda\x36\xff\xc4\x5b\xdc\xc0\xfb\xaa\xb2\xe8\xdc\xbb\xab\x5c\x6c\x02\xf4\x15\xec\x65\xe0\x04\x30\xc4\xdd\xe5\x2f\xa0\x37\xfe\x03\x6e\x6e\x40\xb4\x7e\x77\x19\x1e\xc3\x6f\x21\x48\xae\xe0\x7f\x1f\xc6\x69\x68\x7e\x7f\xb7\x7c\x0c\x9b\x3c\xf0\x7f\xe9\x8f\xe3\x64\xa8\x78\x10\x3b\xdf\xa2\x5f\x1e\x1b\xbc\xbc\x9a\xcb\x8a\xfc\xb4\x91\x54\x33\x48\xff\xf8\x82\xac\xd2\x81\xe2\x03\xfa\xd0\x9d\x2a\x3e\xe3\x4f\xef\xe6\x22\x9c\x31\xec\xfe\x58\x4c\xc6\xb0\x74\x5d\xc8\x71\xe0\x8a\x90\xf0\xe8\x79\xca\x83\x7a\xd6\x2d\x94\xba\x92\xa5\xf0\x29\x2a\x49\x75\xd2\x2e\xa8\x34\xcb\x18\xd3\x09\x21\x8a\xbb\x85\x80\xeb\x24\xb3\xe7\x67\x03\x98\xd0\xb2\x8f\x1f\x17\xb7\x49\x44\xcf\x94\x26\xd7\x42\xeb\x5a\xa1\xd4\x71\x10\x41\x43\xcc\x70\x96\x39\xd1\x47\x3a\xd0\xc6\x07\x12\x47\xfe\x37\xad\xf6\x6f\x1c\x33\x47\xb1\xc5\x19\xac\x48\xfc\xaa\x0b\xa2\x95\x96\x6a\xf5\x1c\x16\x53\x6a\xd5\x2f\x46\x23\x6d\xd2\x83\x71\x06\x4d\x24\x8c\x64\x81\xf4\xd6\xd5\xa4\xe3\xce\x79\x2d\xb2\x02\xac\x98\x7a\x4c\x19\x05\x16\xc1\x8b\xe8\xfe\x90\x13\xf3\x8d\x9e\x76\x61\x6e\xf5\xd3\xb5\xff\x36\x5f\xcd\x5e\xe7\xac\xdb\xa4\xc3\x8b\x9d\xe5\x4d\xee\xaa\x5e\xbf\x33\xce\x5a\x84\x0e\xa3\xe2\x3a\xbc\x16\xe5\xa7\x03\x91\xea\xb7\xc4\xc2\x84\x97\x81\x26\x9f\xe8\x76\xda\x18\xc0\xe2\xfe\x6e\x79\xc3\x15\xeb\xe1\x31\x97\x3e\x68\x12\x63\x51\x73\x50\xb7\xa1\x1f\x88\xad\xe0\x59\x23\x4c\x6c\xc4\xfb\xe4\xac\x69\x3e\xa6\x4f\x69\xf3\x56\xcb\xcf\x2d\xc2\xe2\x96\xcf\x96\x58\x6b\x7a\x23\xdf\x46\xa1\xcf\x2c\x3a\x94\x32\x9d\x86\x44\xeb\x4d\x2d\xbc\x2c\x39\xac\x71\xcf\x55\x43\xd6\x08\x22\xd3\x99\x20\xe4\xbc\x35\xc7\x58\xb6\xf3\xba\xc5\x4d\x85\x64\x03\x88\x04\x1f\x99\x7c\x21\x47\xdc\x24\x60\xc1\x19\x42\x66\x84\x99\x46\xa4\x37\x05\xf7\xa6\xc2\x6e\x5b\xee\x81\xa7\x0e\x17\x16\xa7\x96\xf4\x36\x69\x74\xd9\x1f\x18\xbe\x02\x87\x2a\x4f\xdb\xc3\xe7\xf4\xec\x6a\x68\x95\xd2\xa2\xf0\xf8\x5d\xdd\xf8\x63\x46\xdf\xc3\x53\x56\x09\xe9\xab\x41\x5b\x17\x2d\x98\x0a\x3d\x77\xbf\x27\x5e\x49\xd1\x69\xd1\xb7\x56\x73\x49\x4f\xe4\x41\x28\x85\x36\x2b\xf0\x78\x0c\x9c\xec\xc0\xac\xcd\x0d\x44\x7c\x1d\xd6\xc3\xfb\x5e\x95\x71\x82\xe0\x76\x2b\xea\x20\xdd\x59\x68\x50\x79\x9d\x3c\xec\xe5\xd5\x0d\x7c\xfd\xd0\x7f\x7e\xcc\x4a\x27\xfd\x71\xcb\x3b\x7c\x44\x7f\x16\x5d\xab\x3c\x95\xd0\xbf\xa2\xde\xfa\xdd\xe5\x15\x7c\xf5\x15\xfc\xdf\x0d\x5c\xf0\x28\x82\x77\xaa\x72\x65\x39\x54\x98\x73\x36\xfe\xf8\x3f\x17\x03\x81\x8f\x45\xff\xaf\xc1\xf9\xff\x8c\xde\x41\x6a\xc1\x38\xe2\x12\x2b\x0a\x63\x86\x4a\x5a\x2c\xbd\x3a\x92\xf5\xce\x59\xae\x92\xac\x80\xb0\x47\xe6\xc6\x4a\x81\x6b\xd7\xf7\x77\xcb\x1f\xe1\x13\x1e\x03\xf9\x25\x10\x4f\x5a\xad\x63\x26\x5b\xf4\xef\xf7\x42\x2a\xf2\xfa\x8f\x61\x39\x19\xee\x61\xc9\xd9\x2c\xc0\x6c\x6c\xb9\xa8\xc1\xc3\x53\xa7\xe3\x38\xcb\xe8\x72\x6a\x64\x07\xa7\x3c\x39\xdc\x37\x86\xe8\x77\x0c\x16\xc7\x23\x03\xd3\xf0\x21\xd5\x70\xa2\x12\x9b\xe2\x72\x67\x8c\xc3\x81\x88\x9d\x39\x10\x28\x13\x3e\x5d\xbb\x0e\xf6\xad\xb0\x41\x5d\x11\xe7\x30\x1a\x0e\x3c\x11\x1b\xec\x13\x6b\xe6\x30\x11\xdc\x19\x0b\xf8\xab\xa0\x4e\x73\x06\x72\x03\x2b\x32\xe8\x8a\x29\xb5\x80\xbd\x50\x2d\xce\x60\xdd\x7a\x58\xc9\x6a\x05\x95\x41\xa7\xdf\x84\x41\x18\x2b\x38\x0c\x48\xa1\xa3\xba\x70\xd8\xc9\x72\x17\x0c\xb0\x89\x16\xe1\x09\x86\x49\x96\x95\x5c\xbb\x2c\x67\x28\x01\x17\x15\x6e\xa8\x61\xbc\x18\xc8\x5b\x6c\x60\x1d\xac\x15\x2b\x55\x6c\xec\x7b\x30\x71\x7b\x10\x22\x48\x80\x93\x7a\xab\x82\x5a\xa4\xc9\x3f\x08\xb4\x61\xb7\x81\x54\x5a\x38\x87\x25\x39\x68\x87\xaa\x71\x31\xaa\x1d\x1c\x76\x86\xb6\xd2\x6f\x3c\xb8\xd6\x62\xb0\xa0\x4f\x73\x1d\x65\xcc\x27\x32\x2d\xe5\xf1\x5c\xde\x10\xb9\x8d\xb0\xa2\x86\x50\x27\x29\x98\x08\x63\xa9\xba\x57\xe8\xa4\xc5\xea\x24\xd7\xc4\x45\x94\xf3\x78\xa8\x59\xa5\x05\x11\x01\x6b\x63\xad\x39\x9c\xdf\xb3\x8b\x16\xe7\x6d\x5b\xfa\x96\x27\x89\x71\x6c\x98\x08\xa8\xc5\xcf\x2d\x3a\x0a\x6b\x0a\x8b\xf9\xd9\x34\xb3\x45\x1f\x42\x24\xd6\xfa\x65\xe4\x3c\x5d\xd5\x86\x9b\x73\xdc\xfd\xdd\x74\x08\x69\xa9\x8a\x61\xae\x98\xae\xcd\x06\x6a\xac\x24\x35\x09\xfd\x58\xa1\x9b\x26\xa4\x7a\x96\xb3\xd8\x3e\xed\xbd\xa6\x74\xa7\x41\xe3\xb0\x50\xc3\xcf\x18\x7b\xf2\xd4\xf3\xa7\xe1\x42\x6a\xb8\x12\xdf\xcc\x44\xa5\x1e\x95\x38\x04\xe5\x29\xbd\xed\x96\xe7\xa2\xa3\xa4\x88\x2c\xc1\xc3\x9a\x4d\x98\xd2\x79\x13\x2b\xa3\x92\xce\x23\x75\x74\xe9\x7b\x15\x05\xa6\xd1\x55\x6c\x13\x07\x8e\xef\x74\xb5\x58\x9b\x3d\x76\x13\xe2\x4e\xe7\x2c\x83\x53\x3d\x0b\x2f\x8d\xab\xd9\x30\xe2\x3c\x87\x38\x57\x77\x6e\xa8\x37\x47\xe2\xcd\xdc\xad\xd3\x92\xc5\x2d\xc5\x6b\xa0\xac\x96\xde\x9a\x02\x72\xd2\x8b\xb8\xde\x24\xa0\x3b\xc5\x27\x34\x1d\x23\xb3\x1b\xc2\x74\xad\x23\xc1\x34\x49\xb8\xcc\xf7\x8a\x08\xa5\x92\x48\x78\x7c\x55\x2d\x94\x15\x95\xc0\x5c\x1a\xd7\xc2\x9e\x9a\xf7\xdd\x54\x68\x20\x52\x49\xe4\x59\xbc\x20\xd2\xe5\x46\x81\xb6\xb8\xbd\x38\xd9\x8d\x31\x36\x6e\x7e\xfa\x72\x7c\xa6\xa3\xed\x74\x4c\xd4\x28\x3e\x08\x6d\x48\xe8\x8c\x98\x24\x0d\xdb\xd9\x71\x93\x94\xf1\xa8\x5c\xa7\xc7\x57\x86\x67\x84\xa4\x4b\x30\xfa\x7d\x71\x98\x26\xfc\x63\xc2\x9c\x00\xef\x79\x9a\x12\x11\x3d\x64\x98\x0c\x66\x51\x55\x39\x96\xbf\x3d\x05\x50\x9e\x8f\xc3\x9c\x73\xd9\x43\x30\x6e\x73\x36\x0f\xc6\xef\x2f\xe3\xca\x80\xa8\x11\xff\xe4\x5c\xd9\x34\xc6\x7a\xac\xee\xef\x96\x4b\xbe\xf7\x49\x45\x59\x70\x4c\xa7\x39\x7b\xb8\x13\xea\x99\x81\x4d\xa7\xa7\x7d\x1b\xff\x32\xfa\x13\x84\xd4\xa2\x69\x42\xcf\xba\x36\x46\xa1\xe0\xfb\x95\x6e\xd8\xc0\x65\x55\x0e\xe5\xf5\x50\x2f\x25\x75\x09\xe0\x82\xd6\x64\xbf\x67\x99\xd3\xc9\x09\x33\xea\xf4\x8d\x31\x6a\x44\x8b\x3e\xc4\xe3\xa7\xa4\x11\xb2\x04\xbb\x68\x2b\xf7\xa8\x63\xcf\xe1\xe2\xc1\x23\x85\x9b\xce\x00\x3c\x12\x9e\xe4\xcc\x61\x71\x7f\x31\x12\xa7\xaa\x59\xc5\x07\x6f\x5b\x24\xd9\x91\x58\x9c\xaf\xd2\xef\x75\xe7\xa1\x33\x5e\x88\x76\x9e\x30\x73\xef\x47\xd2\x2a\xda\x77\x5c\xeb\x5f\xc0\x50\xa5\x1b\x9b\x39\x2b\xbf\x57\xc1\xd0\xe3\xd8\xfc\x0b\x59\xe0\x89\x86\x19\x2c\x0a\x97\x46\xaa\xcf\x04\x63\x1f\x3d\x3f\xb4\x6b\x25\xcb\x2c\x4f\xbe\x30\x30\x9e\x83\x51\x6a\x34\x6e\x28\xa7\x3c\xfb\xf6\xe2\x96\x61\xf6\xb7\x90\xd1\xff\xfe\xf4\xfb\x81\x1e\x11\x65\xf9\x25\x27\x2a\xcc\x53\x88\x96\x8c\x0d\xf7\x21\x5c\xf9\x75\x83\xff\x80\x3e\x5d\x5a\xf4\xa3\x2b\xd8\x7c\x76\xbc\xc6\x74\xc9\xd8\xb5\xc6\xdd\xed\x0c\x21\xa2\xbb\x81\x79\x45\x0e\xec\xcd\x7e\xd3\xf1\x92\x59\x97\x19\x67\x53\x6e\x79\x2a\x57\x9e\x4b\x95\xf1\x8e\x57\xfa\xa4\xf8\x99\x58\x7b\x2e\x59\x92\xe6\xe3\x21\xfa\x2b\x70\x32\x39\xef\x1d\x17\x69\x8b\x13\x35\x3a\xe3\x67\xf9\x75\x5e\xa0\x4e\xf1\x4c\x83\xbb\xef\xfe\xca\x7b\x42\x54\xa2\x6d\xe7\x57\x71\x7e\x52\x35\x11\x06\xa1\x0e\xe2\x18\x2a\xfb\x46\x52\x8b\x56\xa1\xf3\x52\x8b\xc1\xd9\x33\xe1\xfd\x3d\x18\x59\xbe\xd3\xb4\x96\xce\xf1\x95\x43\xb8\x0f\x69\x9d\x37\x75\x97\x3c\x88\xf1\x51\xfa\x5a\x63\x4f\x0d\xa7\x64\x93\xc4\x9d\xb0\x55\xe8\xa2\x08\xb2\x32\x8c\x31\x46\x1c\x72\x9a\x75\x8c\xa7\x78\xac\xe6\x13\xa4\x23\x7c\xdf\x73\x8e\xf0\x39\x4e\x3e\xcd\x19\xc2\x31\x1e\xf5\xbd\x80\x72\x9c\xce\x0c\xf8\x72\xbc\x36\xad\x4e\xe5\x33\x0c\x30\xfb\xc0\x3b\x87\xdf\x94\xb1\x35\xbb\x72\xcb\x64\x7d\x30\x86\x77\xf2\x9f\x78\x3a\x6b\x7d\x65\xf2\x9a\x18\x72\x74\xb5\x3e\x8d\x3b\x16\xb7\xee\xe5\xca\x0a\x6b\xc5\x31\x31\x85\xa7\x57\xbe\x30\x61\x42\x31\x1a\x39\x50\x86\x74\x67\xe6\x15\x2f\xb2\xed\xa2\x27\xf0\x7c\x7f\xc8\xd6\xe4\x06\x41\x32\xd5\xcd\x26\xcf\x43\x29\xb3\x51\xef\xdd\xff\xca\x21\x55\xed\x68\x08\x6e\xf0\x19\xe3\x24\xa7\x11\x5a\x96\xf3\xe7\xfa\xec\xd4\x32\xa7\x6a\xab\x37\x9e\xba\x8d\x13\x25\xb2\xb9\x43\xb2\x41\x89\x94\xfc\xe7\xe7\x7c\xd2\x8d\x64\xa6\x2e\x44\x7f\x7f\x3d\x7a\x49\xdf\x7c\xa6\x51\xb9\x0c\xa4\x9f\xda\x14\x2d\xd5\x15\xfc\xf6\x5b\x7a\xf4\x2e\x76\x2f\xb2\xba\xba\x81\x93\x75\xf4\x77\xf1\xad\xd0\x64\xd5\xa0\x1a\x7b\xb1\x3b\x57\xb0\x60\x7e\x8d\x44\x36\x18\x5c\x05\x77\x2d\x61\x2d\x7c\xb9\x4b\x8d\x60\x77\x2b\xdc\xe1\xe0\x85\x83\xc1\xd7\xcf\x6d\xa3\x6a\xdc\x67\x9d\x10\xb5\xa7\x46\xb5\xaf\x18\xc8\x9e\xdd\xe3\xbf\x33\x89\x0d\x59\x98\xdc\xc8\x39\xb3\x7b\x72\x7e\x28\xdb\x79\x65\x27\xf6\x38\xd4\x3d\x34\xa3\xfc\xbb\x90\xf4\xfa\x69\x2f\xfa\x1f\x9b\x02\xc3\x90\x6f\xbd\xde\xdd\x89\x95\xf5\x09\x66\x40\xa3\xff\xe0\x7c\x3e\xcb\x1f\x7a\xe3\x97\xdd\xa8\x2e\x4f\x22\xa3\x61\xe5\xe0\x47\x07\x5d\xda\x78\x2a\x8d\x2f\xf3\x86\xef\x0c\x55\x8c\xbf\xe2\x89\x17\xf7\x2f\x83\x59\xaf\x71\xe8\x0c\x26\x78\xd5\x34\x08\x27\x00\xd8\x03\x80\xcb\xc7\x5c\x31\x0c\x7e\x27\x08\x92\xdb\x1f\x8b\x7f\x05\x00\x00\xff\xff\x4b\x1a\xcb\xca\xe7\x29\x00\x00" func nonfungibletokenCdcBytes() ([]byte, error) { return bindataRead( @@ -151,7 +151,7 @@ func nonfungibletokenCdc() (*asset, error) { } info := bindataFileInfo{name: "NonFungibleToken.cdc", size: 0, mode: os.FileMode(0), modTime: time.Unix(0, 0)} - a := &asset{bytes: bytes, info: info, digest: [32]uint8{0x8b, 0x48, 0xb5, 0xa0, 0xa9, 0x41, 0x86, 0x3a, 0x1b, 0x2, 0xce, 0x36, 0x78, 0xcb, 0x98, 0x9a, 0xe8, 0xae, 0x62, 0xae, 0x61, 0x27, 0xc0, 0xdb, 0x3a, 0xf7, 0xb, 0x91, 0xa7, 0xcb, 0x80, 0xc1}} + a := &asset{bytes: bytes, info: info, digest: [32]uint8{0x43, 0xf4, 0x6, 0x21, 0x3a, 0x48, 0x3b, 0x64, 0x18, 0xf8, 0xa6, 0x54, 0x84, 0xbe, 0x39, 0xcd, 0x18, 0x58, 0x59, 0x40, 0x46, 0x51, 0xfc, 0x0, 0x76, 0x23, 0x22, 0xee, 0x84, 0xae, 0xc1, 0x82}} return a, nil } diff --git a/lib/go/templates/internal/assets/assets.go b/lib/go/templates/internal/assets/assets.go index 2e35cbe..2c7b85e 100644 --- a/lib/go/templates/internal/assets/assets.go +++ b/lib/go/templates/internal/assets/assets.go @@ -1,6 +1,6 @@ // Code generated by go-bindata. DO NOT EDIT. // sources: -// scripts/borrow_nft.cdc (750B) +// scripts/borrow_nft.cdc (807B) // scripts/get_collection_data.cdc (249B) // scripts/get_collection_ids.cdc (464B) // scripts/get_collection_length.cdc (628B) @@ -16,7 +16,7 @@ // transactions/nft-forwarding/unlink_forwarder_link_collection.cdc (1.104kB) // transactions/setup_account.cdc (1.326kB) // transactions/setup_account_from_nft_reference.cdc (1.415kB) -// transactions/setup_account_to_receive_royalty.cdc (1.471kB) +// transactions/setup_account_to_receive_royalty.cdc (1.474kB) // transactions/test/upgrade_nft_contract.cdc (172B) // transactions/transfer_nft.cdc (2.189kB) // transactions/unlink_collection.cdc (555B) @@ -89,7 +89,7 @@ func (fi bindataFileInfo) Sys() interface{} { return nil } -var _scriptsBorrow_nftCdc = "\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\x84\x92\x4f\x6b\xdb\x40\x10\xc5\xef\xfa\x14\x2f\x3e\x14\x09\x82\x7c\x29\x3d\x98\x38\x26\x75\x2b\xe8\xa1\xa2\x04\xb5\xd7\x32\x5e\x8d\xe2\xa1\xeb\x5d\xb1\x3b\x8a\x1b\x42\xbe\x7b\x91\x37\x96\xed\xb6\x90\x3d\x08\xed\xee\xfc\xf9\xbd\xb7\x33\x9f\xa3\xd9\x4a\x44\x34\x41\x7a\xc5\xc6\x87\xe0\xf7\x11\xe4\x50\x57\x0d\xba\xe0\x77\x20\x18\x6f\x2d\x1b\x15\xef\xb2\x4c\x76\xbd\x0f\x8a\x59\xed\x5d\x35\xb8\x07\xd9\x58\x6e\xfc\x2f\x76\xb3\xe9\xe6\xf3\x6f\xda\xf5\x96\xeb\xaa\x39\x9d\x7d\x65\xa5\x96\x94\x7e\x08\xef\xe3\x2c\xcb\xc8\x18\x8e\x31\x27\x6b\x0b\x74\x83\xc3\x8e\xc4\xe5\xd4\xb6\x81\x63\x5c\xe0\x2e\xfd\x5c\x43\xda\x05\xbe\x7f\x71\xfa\xe1\x7d\x81\xe7\x0c\x00\x2c\x2b\xc8\x18\x3f\x38\xc5\x12\x0f\xac\x77\x69\x73\x4c\x2e\xb2\x29\xec\x44\xfd\x89\x94\xb0\xc4\x09\xac\x0c\x1c\xbd\x7d\xe4\xb5\x77\x1a\xc8\xe8\x88\x95\x8f\x67\x43\x30\xdc\x3c\xf5\xbc\x80\x13\x7b\x8d\x47\xe1\x7d\xda\x8e\xdf\x9b\x0b\x15\x65\x5d\x35\xeb\x8b\x16\xb7\x79\x51\x80\xe2\x15\xde\x88\x5b\x1d\x10\xc7\xb5\x5a\xa1\x27\x27\x26\x9f\x8d\xa1\xf7\x09\x2a\xa0\xf5\x1c\xe1\xbc\xe2\x15\x13\xff\x94\x38\x90\xcd\xfe\x2b\xf6\x9e\x3b\x2c\x8f\x1e\x95\x86\x7a\xda\x88\x15\x15\x8e\x65\x7a\xdd\x9b\x77\xcf\x7f\x3f\x5e\x79\xaa\xfe\x72\x9b\x4f\x78\xe3\xba\x74\xb1\xec\x87\x8d\x15\xf3\x8d\x74\x3b\x45\x15\x67\x32\xd6\x7e\xb0\xed\x01\x3d\xf5\xc2\xd4\xff\x29\x0d\x53\xca\x3f\xab\x7a\x14\x31\x9f\xe3\x63\x4a\x21\x04\xee\x38\xb0\x33\x0c\xf5\x20\xc4\x9e\x8d\x74\x62\x0e\x23\x29\x0e\xba\xe5\xf3\x91\x3c\x5a\xf0\x13\xcb\x4b\x1b\x5e\xf5\xd6\x55\x93\x4b\x5b\x5c\x65\x2f\xd9\x9f\x00\x00\x00\xff\xff\x24\x06\x52\x26\xee\x02\x00\x00" +var _scriptsBorrow_nftCdc = "\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\x84\x92\x4f\x6b\xdb\x40\x10\xc5\xef\xfa\x14\x2f\x3a\x14\x09\x82\x7c\x29\x3d\x98\x38\x26\x75\x2b\xe8\xa1\xa2\x04\xb5\xd7\x32\x5e\x8d\xe2\xa1\xeb\x5d\xb1\x3b\x8a\x13\x42\xbe\x7b\x91\x15\xcb\x76\x63\xe8\x1e\x84\x76\x77\xfe\xfc\xde\xdb\x99\xcd\x50\x6f\x24\x22\x9a\x20\x9d\x62\xed\x43\xf0\xbb\x08\x72\xa8\xca\x1a\x6d\xf0\x5b\x10\x8c\xb7\x96\x8d\x8a\x77\x49\x22\xdb\xce\x07\x45\x5a\x79\x57\xf6\xee\x41\xd6\x96\x6b\xff\x87\x5d\x3a\xdd\x7c\x7d\xa2\x6d\x67\xb9\x2a\xeb\xe3\xd9\x77\x56\x6a\x48\xe9\x97\xf0\x2e\xa6\x49\x42\xc6\x70\x8c\x19\x59\x9b\xa3\xed\x1d\xb6\x24\x2e\xa3\xa6\x09\x1c\xe3\x1c\x77\xe3\xcf\x35\xa4\x99\xe3\xe7\x37\xa7\x9f\x3e\xe6\x78\x49\x00\xc0\xb2\x82\x8c\xf1\xbd\x53\x2c\xf0\xc0\x7a\x37\x6e\x0e\xc9\x79\x32\x85\x1d\xa9\xbf\x90\x12\x16\x38\x82\x15\x81\xa3\xb7\x8f\xbc\xf2\x4e\x03\x19\x1d\xb0\xb2\xe1\xac\x0f\x86\xeb\xe7\x8e\xe7\x70\x62\xaf\xf1\x28\xbc\x1b\xb7\xc3\xf7\xe6\x4c\x45\x51\x95\xf5\xea\xac\xc5\x6d\x96\xe7\xa0\x78\x85\xff\xc4\x2d\xf7\x88\xc3\x5a\x2e\xd1\x91\x13\x93\xa5\x43\xe8\xfd\x08\x15\xd0\x78\x8e\x70\x5e\xf1\x86\x89\x77\x25\xf6\x64\xe9\x45\xb1\xf7\xdc\x62\x71\xf0\xa8\x30\xd4\xd1\x5a\xac\xa8\x70\x2c\xc6\xd7\xbd\xf9\xf0\xf2\xef\xe3\x15\xc7\xea\xaf\xb7\xd9\x84\x37\xac\x73\x17\x8b\xae\x5f\x5b\x31\x3f\x48\x37\x53\x54\x7e\x22\x63\xe5\x7b\xdb\xec\xd1\xc7\x5e\x98\xfa\x3f\x8f\xc3\x34\xe6\x9f\x54\x3d\x88\x98\xcd\xf0\x79\x4c\x21\x04\x6e\x39\xb0\x33\x0c\xf5\x20\xc4\x8e\x8d\xb4\x62\xf6\x23\x29\x0e\xba\xe1\xd3\x91\x3c\x58\xf0\x1b\x8b\x73\x1b\xde\xf4\x56\x65\x9d\x49\x93\x5f\x30\x7d\xa8\x37\x79\xcd\x4f\x12\xf5\x7d\xf9\xab\x34\x4f\x5e\x93\xbf\x01\x00\x00\xff\xff\x08\xdd\x96\x13\x27\x03\x00\x00" func scriptsBorrow_nftCdcBytes() ([]byte, error) { return bindataRead( @@ -105,7 +105,7 @@ func scriptsBorrow_nftCdc() (*asset, error) { } info := bindataFileInfo{name: "scripts/borrow_nft.cdc", size: 0, mode: os.FileMode(0), modTime: time.Unix(0, 0)} - a := &asset{bytes: bytes, info: info, digest: [32]uint8{0xbf, 0xf8, 0x34, 0x8a, 0x0, 0x6d, 0x8b, 0x49, 0xc, 0x88, 0x85, 0xf2, 0xf7, 0xc9, 0xaa, 0x9d, 0x3d, 0xff, 0x73, 0x89, 0x8c, 0xc9, 0x12, 0xcd, 0xb8, 0x63, 0x69, 0x10, 0x78, 0x45, 0x49, 0xab}} + a := &asset{bytes: bytes, info: info, digest: [32]uint8{0xdc, 0xcc, 0x49, 0x70, 0x34, 0x62, 0x60, 0xa0, 0xc0, 0x2e, 0xb3, 0x11, 0x50, 0xd0, 0xe1, 0x66, 0x97, 0xf7, 0xe9, 0x17, 0x64, 0xfe, 0x84, 0x75, 0x13, 0xd1, 0x82, 0x6b, 0x34, 0x33, 0xde, 0x20}} return a, nil } @@ -189,7 +189,7 @@ func scriptsGet_collection_length_from_storageCdc() (*asset, error) { return a, nil } -var _scriptsGet_contract_storage_pathCdc = "\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\x84\x51\xcd\x6a\xc3\x30\x0c\xbe\xfb\x29\xd4\x1c\x86\x03\x25\x0f\x50\x9a\x96\xd2\xb1\xdb\xc6\xd8\xca\xee\xaa\xad\x76\x06\xd7\x2e\xb2\xd2\x32\x46\xdf\x7d\x28\xe9\xdf\xd8\x61\x3a\x84\xe8\x8b\xbe\x1f\x29\x61\xb7\xcf\x2c\x50\x3d\x93\xa0\x47\xc1\x8f\x40\xc7\x52\x99\x0b\xac\xed\x1b\x95\x1c\x0f\xc4\x95\x31\xe8\x1c\x95\x62\x31\xc6\x1a\x36\x5d\x82\x1d\x86\x64\xd1\x7b\x9e\xc0\xc2\x7b\xa6\x52\xc6\x90\x70\x47\x13\x78\x17\x0e\x69\x5b\xeb\x4b\x66\xdc\xd2\x2b\xca\xe7\x1c\xbe\x0d\x00\x40\x24\x01\x81\x16\x56\x5f\x7b\x9a\xfe\x32\x6e\x5e\x9e\x56\xcb\x1c\x23\x39\x09\x39\x3d\xa2\xe0\xcc\xd6\x57\xce\x3a\x33\xe7\x23\xf9\x65\x4e\xc2\xe8\x54\x62\x4b\xb2\x70\x2e\x77\x49\xfa\x18\x75\xe3\xce\xdf\x4a\x33\x4c\x4f\x1f\xee\x57\x98\xd9\x21\x9d\x3e\x07\x5d\xad\xf9\x1c\xf6\x98\x82\xb3\xd5\x85\x0d\x2e\x77\xd1\x43\xca\x02\x6b\xba\xfa\x56\xb5\xb9\x66\x39\x04\x3a\x42\xfb\x27\x52\xc3\x83\xd3\xa5\x57\x73\xab\x58\xc7\x8e\x74\xdf\x31\xa4\x10\xc7\x3d\x5d\xdb\x09\xc8\x90\x23\x6c\xce\x92\xad\x0e\x9c\x0f\xa5\xc5\x24\x1d\x27\x05\x7b\xe8\x74\x8b\xe0\x3c\xb4\x3d\x69\x04\x58\x46\xf0\xcf\x21\xcd\x9d\x98\xf3\x4d\xb9\xfd\x16\x73\x32\x3f\x01\x00\x00\xff\xff\x7e\x06\x7a\xa3\x06\x02\x00\x00" +var _scriptsGet_contract_storage_pathCdc = "\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\x84\x51\xcd\x6a\xc3\x30\x0c\xbe\xfb\x29\xd4\x1c\x46\x02\x25\x0f\x50\x9a\x96\xd2\xb1\xdb\xc6\xd8\xca\xee\xaa\xac\x76\x06\xd7\x2e\xb2\xd2\x32\x46\xdf\x7d\x38\xee\xdf\xd8\x61\x3a\x84\xe8\x8b\xbe\x1f\x29\x6e\xb7\x8f\xa2\x50\x3d\xb3\xa2\x45\xc5\x0f\xc7\xc7\x54\x99\x0b\x9c\xdb\x37\x4e\xd1\x1f\x58\x2a\x63\x90\x88\x53\xaa\xd1\xfb\x06\x36\x7d\x80\x1d\xba\x50\xa3\xb5\x32\x81\x85\xb5\xc2\x29\x8d\x21\xe0\x8e\x27\xf0\xae\xe2\xc2\xb6\xc9\x2f\x51\x70\xcb\xaf\xa8\x9f\x73\xf8\x36\x00\x00\x9e\x15\x14\x3a\x58\x7d\xed\x79\xfa\xcb\xb8\x7d\x79\x5a\x2d\xa3\xf7\x4c\xea\x62\x78\x44\xc5\x59\xdd\x5c\x39\xeb\x28\x12\x8f\x6c\x97\x31\xa8\x20\x65\x89\x2d\xeb\x82\x28\xf6\x41\x87\x18\x4d\x4b\xe7\x6f\xa9\x2d\xd3\xd3\x87\xfb\x15\x66\x75\x49\x97\x9f\x45\x37\xd7\x7c\x0e\x7b\x0c\x8e\xea\xea\xc2\x06\x8a\xbd\xb7\x10\xa2\xc2\x9a\xaf\xbe\x55\x63\xae\x59\x0e\x8e\x8f\xd0\xfd\x89\xd4\x4a\x71\xba\xf4\xd9\xbc\xce\x58\x2f\xc4\x79\xdf\x09\x04\xe7\xc7\x03\xbd\xb4\x5a\x72\xb8\xcd\x59\xb2\xcb\x03\xe7\x43\xe5\x12\xd6\x5e\x42\x06\x07\xe8\x74\x8b\x40\x16\xba\x81\x34\x02\x4c\x23\xf8\xe7\x90\xe6\x4e\x8c\x6c\x9b\x6e\xbf\xc5\x9c\xcc\x4f\x00\x00\x00\xff\xff\x4c\xda\xcc\xe8\x06\x02\x00\x00" func scriptsGet_contract_storage_pathCdcBytes() ([]byte, error) { return bindataRead( @@ -205,7 +205,7 @@ func scriptsGet_contract_storage_pathCdc() (*asset, error) { } info := bindataFileInfo{name: "scripts/get_contract_storage_path.cdc", size: 0, mode: os.FileMode(0), modTime: time.Unix(0, 0)} - a := &asset{bytes: bytes, info: info, digest: [32]uint8{0x6b, 0x1c, 0xf2, 0xdd, 0x26, 0xa0, 0x77, 0xc1, 0x3d, 0x8c, 0xd5, 0xf, 0xa, 0x9b, 0x23, 0xed, 0x5e, 0x3, 0xc1, 0x66, 0xd2, 0xf3, 0x81, 0x38, 0x7f, 0x80, 0x28, 0x67, 0x19, 0x3c, 0xed, 0xfa}} + a := &asset{bytes: bytes, info: info, digest: [32]uint8{0x9e, 0x33, 0x1, 0xe9, 0x3e, 0x8c, 0xe, 0x3e, 0x11, 0x74, 0xf0, 0x70, 0x27, 0x6e, 0xba, 0x39, 0x7, 0xd5, 0xca, 0xc3, 0x6, 0x4d, 0x2b, 0x56, 0x8b, 0x6e, 0xd5, 0x1b, 0x9, 0x11, 0xc6, 0x3c}} return a, nil } @@ -409,7 +409,7 @@ func transactionsSetup_account_from_nft_referenceCdc() (*asset, error) { return a, nil } -var _transactionsSetup_account_to_receive_royaltyCdc = "\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\x94\x53\x5d\x6b\x2b\x37\x10\x7d\xdf\x5f\x31\xf8\x21\xb1\x61\xb1\xdf\x4d\x53\x48\x5d\x02\x81\x96\x86\x7c\xf5\xd5\x63\xed\xec\xee\x10\x59\x12\xd2\x28\xce\x12\xf2\xdf\x8b\xb4\x1f\xf6\x96\xdc\x0b\xd7\x6f\x5e\xcd\x9c\x39\x73\xce\x99\xcd\x66\x03\xcf\x2d\x07\x10\x8f\x26\xa0\x12\xb6\x06\x38\x00\x82\xd0\xd1\x69\x14\x82\xda\xfa\xf4\xf7\xfc\x5e\xa4\x26\xb1\xa0\x3c\xa5\x77\x04\x43\x27\xd0\x6c\xde\x80\x0d\x48\x4b\xec\x01\x95\xb2\xd1\x48\xaa\x3a\x10\xc4\x40\x55\x86\xf1\xa4\x88\xdf\xd9\x34\xe0\x6d\x87\x5a\x98\x42\xf1\x2d\x03\x85\x66\xd6\x88\xa6\x83\x3a\x9a\x86\x0f\x9a\x40\xec\x1b\x99\x12\x4e\x2d\xab\x36\x71\x0d\x8e\x14\xd7\x4c\x15\x1c\xba\x34\x1f\xf6\xef\x18\xb5\x3c\xa0\xb4\x7b\x40\xdf\xc4\x23\x19\x49\x73\xf2\xac\xfb\x3a\xd7\x8c\x0c\x4f\x68\x24\x24\x9e\x3d\x37\x3a\x33\x4b\xdb\xdc\xfd\xf5\xcf\xbf\x65\xaa\xef\xae\xb5\x4e\x74\x60\xbf\x09\x62\x3d\x36\xb4\xa9\xb5\x3d\x3d\x27\x2a\xaf\x69\xda\xfe\x02\xbc\xcb\xa8\x97\xa0\x2c\x09\xed\xe5\xe9\xcf\x5d\x39\x14\xd8\xa8\xab\x0c\x78\xc7\x28\x19\x66\x9d\x71\x9e\x7a\xf4\x44\x3e\x23\xa2\xa9\x20\x58\xb0\x66\x3d\x28\x45\xe0\x50\xda\xb3\x34\x69\x19\x17\x0f\x9a\xd5\xe0\x41\x18\x1c\xc9\x65\xd2\xa2\x0c\xb6\x40\x1d\x25\x7a\x2a\x53\x05\x7d\x38\x52\x42\xd5\x05\xc7\x69\x5a\x43\x86\x3c\xab\xb9\xcc\x2a\xf3\x3d\xe4\x34\x9c\xd0\x57\x7d\x6b\x16\xd2\x39\x6f\x9d\xe7\x14\x85\xac\x7b\x51\xf0\xd1\x59\x2f\xb0\xb8\x1b\x1c\xcb\xeb\x2d\xa6\xcf\x7f\x93\x60\x85\x82\xaf\x4c\xa7\xb0\x28\x8a\x0b\xe3\x97\x93\x73\x5b\xb8\x50\x62\x05\x9f\x45\x01\x00\xe0\x3c\x39\xf4\xb4\x0c\xdc\x18\xf2\x5b\xc0\x28\xed\xf2\x0f\xeb\xbd\x3d\xbd\xa2\x8e\x54\xc2\x7d\x08\x91\x86\xd6\x1d\x3a\x3c\xb0\x66\xe9\x76\xd6\x88\xb7\x5a\x93\x2f\xe1\x21\x89\x15\xda\xf3\x63\x09\x2f\xc6\xfd\xff\xe3\x0a\xae\x6e\xfb\x88\x4c\xc3\xd3\x6f\xb3\x81\x47\x92\xe8\x0d\x10\x7a\xdd\x01\xcf\xd3\x54\x59\x0a\xe6\x5a\xa0\xc5\xf7\x74\x18\x33\x01\x20\xfb\x3b\x21\x71\x0d\xfd\x16\xeb\x21\x50\xeb\x43\xde\xe3\xb7\xab\xcf\x59\x5b\x1f\x8b\xaf\xdf\x97\xb5\xb7\xc7\x2d\x4c\x02\xad\xe0\xe6\x06\x0c\x6b\xf8\x9c\x20\xb3\x42\x68\x58\x2d\x17\xb7\x7d\xe1\x94\x90\xf3\x8d\xcc\xcf\xa8\x4f\x49\xa2\x0d\xc6\x0a\xd0\x07\x07\x59\xac\x26\xc4\xaf\xd9\xe6\xbb\xf1\xe0\x87\xbc\xa9\x49\xad\x31\x0c\x99\x6b\x1f\x3a\x6b\x74\x97\x72\x66\x03\x85\x4b\x90\x54\x56\x91\xb3\x81\x25\x71\xe9\xef\x5d\x5a\x6f\x63\xd3\xe6\xc7\xc7\x3e\x8f\x1e\xd8\x08\xf9\x1a\x15\x4d\xed\x83\x60\xd3\x5c\xa6\xb0\x8e\xa3\x77\xcb\x59\xae\xd6\x0d\xc9\x63\x3e\xe5\x6e\x04\xcc\xc6\xab\xa4\xdd\x72\x75\x5e\x51\x93\xf4\x5a\xed\xd0\xc1\xcd\xb7\x23\x46\x83\x38\x65\xeb\x87\xfe\x9c\x9d\xf9\x29\xdf\x91\xed\x38\xb3\x04\x94\x2d\xfc\x1a\xf7\xa2\xf7\xe6\xab\xf8\x2f\x00\x00\xff\xff\xac\x58\xbb\x22\xbf\x05\x00\x00" +var _transactionsSetup_account_to_receive_royaltyCdc = "\x1f\x8b\x08\x00\x00\x00\x00\x00\x00\xff\x94\x53\x4d\x6b\xdb\x40\x10\xbd\xeb\x57\x0c\x3e\x24\x36\x08\xfb\x6e\x9a\x40\xea\x12\x08\xb4\x34\xe4\xab\x57\x8f\x57\x23\x69\xc8\x7a\x57\xec\xce\xc6\x11\xc1\xff\xbd\xec\xea\xc3\x56\x1b\x0a\xf5\xcd\xda\x99\x37\x6f\xde\x7b\xb3\x5a\xad\xe0\xa9\x66\x0f\xe2\xd0\x78\x54\xc2\xd6\x00\x7b\x40\x10\xda\x37\x1a\x85\xa0\xb4\x2e\xfe\x3d\xbd\x67\xb1\x49\x2c\x28\x47\xf1\x1d\xc1\xd0\x01\x34\x9b\x57\x60\x03\x52\x13\x3b\x40\xa5\x6c\x30\x12\xab\x76\x04\xc1\x53\x91\x60\x1c\x29\xe2\x37\x36\x15\x38\xdb\xa2\x16\x26\x9f\x7d\xca\x40\xa1\x99\x34\xa2\x69\xa1\x0c\xa6\xe2\x9d\x26\x10\xfb\x4a\x26\x87\x43\xcd\xaa\x8e\x5c\x7d\x43\x8a\x4b\xa6\x02\x76\x6d\x9c\x0f\xdb\x37\x0c\x5a\xee\x51\xea\x2d\xa0\xab\xc2\x9e\x8c\xc4\x39\x69\xd6\x5d\x99\x6a\x06\x86\x07\x34\xe2\x23\xcf\x8e\x1b\x9d\x98\xc5\x6d\x6e\xbf\xff\xfc\x95\xc7\xfa\xf6\x52\xeb\x48\x07\xb6\x2b\x2f\xd6\x61\x45\xab\x52\xdb\xc3\x53\xa4\xf2\x12\xa7\x6d\xcf\xc0\xdb\x84\x7a\x0e\xca\x12\xd1\x9e\x1f\xbf\x6d\xf2\xbe\xc0\x06\x5d\x24\xc0\x5b\x46\x49\x30\xcb\x84\xf3\xd8\xa1\x47\xf2\x09\x11\x4d\x01\xde\x82\x35\xcb\x5e\x29\x82\x06\xa5\x3e\x49\x13\x97\x69\xc2\x4e\xb3\xea\x3d\xf0\xbd\x23\xa9\x4c\x6a\x94\xde\x16\x28\x83\x04\x47\x79\xac\xa0\xf7\x86\x94\x50\x71\xc6\x71\x9c\x56\x91\x21\xc7\x6a\x2a\xb3\x4a\x7c\x77\x29\x0d\x07\x74\x45\xd7\x9a\x84\x6c\x1a\x67\x1b\xc7\x31\x0a\x49\xf7\x2c\xe3\x7d\x63\x9d\xc0\xec\xb6\x77\x2c\xad\x37\x1b\x3f\xff\x20\xc1\x02\x05\x5f\x98\x0e\x7e\x96\x65\x67\xc6\xcf\x47\xe7\xd6\x70\xa6\xc4\x02\x3e\xb2\x0c\x00\xa0\x71\xd4\xa0\xa3\xb9\xe7\xca\x90\x5b\x03\x06\xa9\xe7\x5f\xad\x73\xf6\xf0\x82\x3a\x50\x0e\x77\xde\x07\xea\x5b\x37\xd8\xe0\x8e\x35\x4b\xbb\xb1\x46\x9c\xd5\x9a\x5c\x0e\xf7\x51\x2c\x5f\x9f\x1e\x73\x78\x36\xcd\x9f\x1f\x17\x70\x71\xd3\x45\x64\x1c\x1e\x7f\xab\x15\x3c\x90\x04\x67\x80\xd0\xe9\x16\x78\x9a\xa6\xc2\x92\x37\x97\x02\x35\xbe\xc5\xc3\x98\x08\x00\xc9\xdf\x11\x89\x4b\xe8\xb6\x58\xf6\x81\x5a\xee\xd2\x1e\x5f\x2e\x3e\x26\x6d\xcb\x87\xce\x1f\x77\xbc\x9e\x97\xce\xee\xd7\x30\x6a\xb4\x80\xab\x2b\x30\xac\xe1\x63\x44\x4d\x22\xa1\x61\x35\x9f\xdd\x74\x85\x63\x48\x4e\x67\x32\xbd\xa4\x2e\x28\x91\x39\x18\x2b\x40\xef\xec\x65\xb6\x18\x11\x8f\x93\xe5\x37\xc3\xcd\xf7\x91\x53\xa3\x60\x43\x1e\xd2\x96\x5d\xee\xac\xd1\x6d\x8c\x9a\xf5\xe4\xcf\x41\x62\x59\x41\x8d\xf5\x2c\x91\x4b\x77\xf2\x52\x3b\x1b\xaa\x3a\x3d\x0e\x2b\x03\x1b\x21\x57\xa2\xa2\xb1\xbd\xd7\x6c\x9c\xcb\xe4\x97\x61\xb0\x6f\x3e\x89\xd6\xb2\x22\x79\x48\xd7\xdc\x0e\x80\xc9\x7b\x15\xb5\x9b\x2f\x4e\x2b\x6a\x92\x4e\xab\x0d\x36\x70\xf5\xe9\x88\xc1\x23\x8e\xf1\xfa\xcb\xa2\xb4\xf3\xf1\xfa\x94\xde\xc5\x3f\xf9\x0e\x6c\x87\x99\x39\xa0\xac\xe1\xff\xb8\x67\x9d\x37\xc7\xec\x77\x00\x00\x00\xff\xff\x88\x90\xa3\xae\xc2\x05\x00\x00" func transactionsSetup_account_to_receive_royaltyCdcBytes() ([]byte, error) { return bindataRead( @@ -425,7 +425,7 @@ func transactionsSetup_account_to_receive_royaltyCdc() (*asset, error) { } info := bindataFileInfo{name: "transactions/setup_account_to_receive_royalty.cdc", size: 0, mode: os.FileMode(0), modTime: time.Unix(0, 0)} - a := &asset{bytes: bytes, info: info, digest: [32]uint8{0xcd, 0xdd, 0x80, 0xbf, 0x19, 0xe8, 0xc2, 0x7d, 0x81, 0x54, 0x36, 0x0, 0xdf, 0xa6, 0xee, 0xfb, 0x66, 0x41, 0x30, 0x35, 0x7c, 0xbf, 0x31, 0xa0, 0x1b, 0xb7, 0x46, 0x66, 0xe4, 0x9a, 0xeb, 0x71}} + a := &asset{bytes: bytes, info: info, digest: [32]uint8{0x30, 0x3f, 0x26, 0x1, 0x6e, 0x4c, 0x2c, 0xf5, 0x24, 0xac, 0x71, 0xda, 0xd0, 0xb1, 0x79, 0x89, 0x68, 0x55, 0x6e, 0x4a, 0x41, 0x7f, 0x67, 0xcf, 0xe7, 0x3a, 0xca, 0x7a, 0x0, 0x76, 0xd5, 0xe}} return a, nil } diff --git a/lib/go/templates/templates.go b/lib/go/templates/templates.go index e7665c5..db53b69 100644 --- a/lib/go/templates/templates.go +++ b/lib/go/templates/templates.go @@ -14,6 +14,7 @@ var ( placeholderMetadataViews = regexp.MustCompile(`"MetadataViews"`) placeholderFungibleToken = regexp.MustCompile(`"FungibleToken"`) placeholderViewResolver = regexp.MustCompile(`"ViewResolver"`) + placeholderFlowToken = regexp.MustCompile(`"FlowToken"`) ) func replaceAddresses(code string, nftAddress, exampleNFTAddress, metadataAddress, ftAddress, viewResolverAddress flow.Address) []byte { diff --git a/lib/go/test/metadata_test.go b/lib/go/test/metadata_test.go index ef5097e..3b31da2 100644 --- a/lib/go/test/metadata_test.go +++ b/lib/go/test/metadata_test.go @@ -1,8 +1,6 @@ package test import ( - "encoding/json" - "fmt" "testing" "github.com/onflow/cadence" @@ -10,7 +8,6 @@ import ( "github.com/onflow/cadence/runtime/common" "github.com/onflow/flow-go-sdk" "github.com/onflow/flow-go-sdk/crypto" - "github.com/stretchr/testify/assert" "github.com/onflow/flow-nft/lib/go/templates" ) @@ -47,277 +44,6 @@ func TestSetupRoyaltyReceiver(t *testing.T) { }) } -func TestGetNFTMetadata(t *testing.T) { - b, adapter, accountKeys := newTestSetup(t) - - // Create new keys for the NFT contract account - // and deploy all the NFT contracts - exampleNFTAccountKey, exampleNFTSigner := accountKeys.NewWithSigner() - nftAddress, metadataAddress, exampleNFTAddress, _ := deployNFTContracts(t, b, adapter, accountKeys, exampleNFTAccountKey) - - // Mint a single NFT with standard royalty cuts and metadata - mintExampleNFT(t, b, - accountKeys, - nftAddress, metadataAddress, exampleNFTAddress, - exampleNFTAccountKey, - exampleNFTSigner) - - t.Run("Should be able to verify the metadata of the minted NFT", func(t *testing.T) { - - // Set expected NFTCollectionData values - const ( - pathName = "cadenceExampleNFTCollection" - collectionType = "A.e03daebed8ca0615.ExampleNFT.Collection" - providerEntitlement = "auth(A.179b6b1cb6755e31.NonFungibleToken.Withdraw)" - ) - - idsScript := templates.GenerateGetCollectionIDsScript(nftAddress, exampleNFTAddress) - idsResult := executeScriptAndCheck( - t, b, - idsScript, - [][]byte{ - jsoncdc.MustEncode(cadence.NewAddress(exampleNFTAddress)), - jsoncdc.MustEncode(cadence.Path{Domain: common.PathDomainPublic, Identifier: pathName}), - }, - ) - mintedID := idsResult.(cadence.Array).Values[0].(cadence.UInt64) - - // Run a script to get the Display view for the specified NFT ID - script := templates.GenerateGetNFTMetadataScript(nftAddress, exampleNFTAddress, metadataAddress) - result := executeScriptAndCheck( - t, b, - script, - [][]byte{ - jsoncdc.MustEncode(cadence.NewAddress(exampleNFTAddress)), - jsoncdc.MustEncode(mintedID), - }, - ) - - // Expected metadata - const ( - name = "Example NFT 0" - description = "This is an example NFT" - thumbnail = "example.jpeg" - ) - externalURL := "https://example-nft.onflow.org/" + mintedID.String() - - nftResult := result.(cadence.Struct) - - nftType := fmt.Sprintf("A.%s.ExampleNFT.NFT", exampleNFTAddress) - - assert.Equal(t, cadence.String(name), nftResult.Fields[0]) - assert.Equal(t, cadence.String(description), nftResult.Fields[1]) - assert.Equal(t, cadence.String(thumbnail), nftResult.Fields[2]) - assert.Equal(t, cadence.NewAddress(exampleNFTAddress), nftResult.Fields[3]) - assert.Equal(t, cadence.String(nftType), nftResult.Fields[4]) - - // TODO: To verify the return data from the script with the expected data. - royalties := toJson(t, nftResult.Fields[5]) - // Declared an empty interface of type Array - var results map[string]interface{} - - // Unmarshal or Decode the JSON to the interface. - json.Unmarshal([]byte(royalties), &results) - - // Verify external URL view result is as expected - assert.Equal(t, cadence.String(externalURL), nftResult.Fields[6]) - - // Assert that the serial number is correct - assert.Equal(t, mintedID, nftResult.Fields[7]) - - assert.Equal(t, cadence.Path{Domain: common.PathDomainPublic, Identifier: pathName}, nftResult.Fields[8]) - assert.Equal(t, cadence.Path{Domain: common.PathDomainStorage, Identifier: pathName}, nftResult.Fields[9]) - assert.Equal(t, cadence.String(fmt.Sprintf("&%s", collectionType)), nftResult.Fields[11]) - - // Verify NFTCollectionDisplay results are as expected - const ( - collectionName = "The Example Collection" - collectionDescription = "This collection is used as an example to help you develop your next Flow NFT." - collectionImage = "https://assets.website-files.com/5f6294c0c7a8cdd643b1c820/5f6294c0c7a8cda55cb1c936_Flow_Wordmark.svg" - collectionExternalURL = "https://example-nft.onflow.org" - ) - assert.Equal(t, cadence.String(collectionName), nftResult.Fields[12]) - assert.Equal(t, cadence.String(collectionDescription), nftResult.Fields[13]) - assert.Equal(t, cadence.String(collectionExternalURL), nftResult.Fields[14]) - assert.Equal(t, cadence.String(collectionImage), nftResult.Fields[15]) - assert.Equal(t, cadence.String(collectionImage), nftResult.Fields[16]) - - // TODO: Verify `nftResult.Fields[19]` is equal to a {String: String} dictionary - // with key `twitter` and value `https://twitter.com/flow_blockchain` - - // Verify Edition results are as expected - const ( - editionName = "Example NFT Edition" - editionNum = 0 - ) - expectedName, _ := cadence.NewString(editionName) - assert.Equal(t, cadence.NewOptional(expectedName), nftResult.Fields[18].(cadence.Struct).Fields[0]) - assert.Equal(t, mintedID, nftResult.Fields[18].(cadence.Struct).Fields[1]) - assert.Equal(t, cadence.NewOptional(nil), nftResult.Fields[18].(cadence.Struct).Fields[2]) - - mintedTimeName, _ := cadence.NewString("mintedTime") - - traitsView := nftResult.Fields[19].(cadence.Struct) - traits := traitsView.Fields[0].(cadence.Array) - - blockNumberName, _ := cadence.NewString("mintedBlock") - blockNumberTrait := traits.Values[0].(cadence.Struct) - assert.Equal(t, blockNumberName, blockNumberTrait.Fields[0]) - assert.Equal(t, cadence.NewUInt64(16), blockNumberTrait.Fields[1]) - assert.Equal(t, cadence.NewOptional(nil), blockNumberTrait.Fields[2]) - assert.Equal(t, cadence.NewOptional(nil), blockNumberTrait.Fields[3]) - - mintTrait := traits.Values[1].(cadence.Struct) - mintedTimeDisplayType, _ := cadence.NewString("Date") - assert.Equal(t, mintedTimeName, mintTrait.Fields[0]) - assert.Equal(t, cadence.NewOptional(mintedTimeDisplayType), mintTrait.Fields[2]) - assert.Equal(t, cadence.NewOptional(nil), mintTrait.Fields[3]) - - fooTrait := traits.Values[2].(cadence.Struct) - fooName, _ := cadence.NewString("foo") - fooValue, _ := cadence.NewString("bar") - fooRarityOptional := fooTrait.Fields[3].(cadence.Optional) - fooRarity := fooRarityOptional.Value.(cadence.Struct) - rarityDescription, _ := cadence.NewString("Common") - assert.Equal(t, fooName, fooTrait.Fields[0]) - assert.Equal(t, cadence.NewOptional(fooValue), fooTrait.Fields[1]) - fooRarityScore := fooRarity.Fields[0].(cadence.Optional).Value - score, _ := cadence.NewUFix64("10.0") - assert.Equal(t, fooRarityScore, score) - fooRarityMax := fooRarity.Fields[1].(cadence.Optional).Value - max, _ := cadence.NewUFix64("100.0") - assert.Equal(t, max, fooRarityMax) - assert.Equal(t, fooRarity.Fields[2], cadence.NewOptional(rarityDescription)) - }) -} - -func TestGetNFTView(t *testing.T) { - b, adapter, accountKeys := newTestSetup(t) - - // Create new keys for the NFT contract account - // and deploy all the NFT contracts - exampleNFTAccountKey, exampleNFTSigner := accountKeys.NewWithSigner() - nftAddress, metadataAddress, exampleNFTAddress, viewResolverAddress := deployNFTContracts(t, b, adapter, accountKeys, exampleNFTAccountKey) - - // Mint a single NFT with standard royalty cuts and metadata - mintExampleNFT(t, b, - accountKeys, - nftAddress, metadataAddress, exampleNFTAddress, - exampleNFTAccountKey, - exampleNFTSigner) - - t.Run("Should be able to verify the nft metadata view of the minted NFT", func(t *testing.T) { - - // Set expected NFTCollectionData values - // Set expected NFTCollectionData values - const ( - pathName = "cadenceExampleNFTCollection" - collectionType = "A.e03daebed8ca0615.ExampleNFT.Collection" - providerEntitlement = "auth(A.179b6b1cb6755e31.NonFungibleToken.Withdrawable)" - ) - - idsScript := templates.GenerateGetCollectionIDsScript(nftAddress, exampleNFTAddress) - idsResult := executeScriptAndCheck( - t, b, - idsScript, - [][]byte{ - jsoncdc.MustEncode(cadence.NewAddress(exampleNFTAddress)), - jsoncdc.MustEncode(cadence.Path{Domain: common.PathDomainPublic, Identifier: pathName}), - }, - ) - mintedID := idsResult.(cadence.Array).Values[0].(cadence.UInt64) - - // Run a script to get the Display view for the specified NFT ID - script := templates.GenerateGetNFTViewScript(nftAddress, exampleNFTAddress, metadataAddress, viewResolverAddress) - result := executeScriptAndCheck( - t, b, - script, - [][]byte{ - jsoncdc.MustEncode(cadence.NewAddress(exampleNFTAddress)), - jsoncdc.MustEncode(mintedID), - }, - ) - - // Expected metadata - const ( - name = "Example NFT 0" - description = "This is an example NFT" - thumbnail = "example.jpeg" - ) - externalURL := "https://example-nft.onflow.org/" + mintedID.String() - - nftResult := result.(cadence.Struct) - - assert.Equal(t, mintedID, nftResult.Fields[0]) - assert.Equal(t, cadence.String(name), nftResult.Fields[2]) - assert.Equal(t, cadence.String(name), nftResult.Fields[2]) - assert.Equal(t, cadence.String(description), nftResult.Fields[3]) - assert.Equal(t, cadence.String(thumbnail), nftResult.Fields[4]) - - royalties := toJson(t, nftResult.Fields[5]) - // Declared an empty interface of type Array - var results map[string]interface{} - - // Unmarshal or Decode the JSON to the interface. - json.Unmarshal([]byte(royalties), &results) - - // Verify external URL view result is as expected - assert.Equal(t, cadence.String(externalURL), nftResult.Fields[6]) - - assert.Equal(t, cadence.Path{Domain: common.PathDomainPublic, Identifier: pathName}, nftResult.Fields[7]) - assert.Equal(t, cadence.Path{Domain: common.PathDomainStorage, Identifier: pathName}, nftResult.Fields[8]) - assert.Equal(t, cadence.String(fmt.Sprintf("&%s", collectionType)), nftResult.Fields[9]) - assert.Equal(t, cadence.String(fmt.Sprintf("&%s", collectionType)), nftResult.Fields[10]) - - // Verify NFTCollectionDisplay results are as expected - const ( - collectionName = "The Example Collection" - collectionDescription = "This collection is used as an example to help you develop your next Flow NFT." - collectionImage = "https://assets.website-files.com/5f6294c0c7a8cdd643b1c820/5f6294c0c7a8cda55cb1c936_Flow_Wordmark.svg" - collectionExternalURL = "https://example-nft.onflow.org" - ) - assert.Equal(t, cadence.String(collectionName), nftResult.Fields[11]) - assert.Equal(t, cadence.String(collectionDescription), nftResult.Fields[12]) - assert.Equal(t, cadence.String(collectionExternalURL), nftResult.Fields[13]) - assert.Equal(t, cadence.String(collectionImage), nftResult.Fields[14]) - assert.Equal(t, cadence.String(collectionImage), nftResult.Fields[15]) - - mintedTimeName, _ := cadence.NewString("mintedTime") - - traitsView := nftResult.Fields[17].(cadence.Struct) - traits := traitsView.Fields[0].(cadence.Array) - - blockNumberName, _ := cadence.NewString("mintedBlock") - blockNumberTrait := traits.Values[0].(cadence.Struct) - assert.Equal(t, blockNumberName, blockNumberTrait.Fields[0]) - assert.Equal(t, cadence.NewUInt64(16), blockNumberTrait.Fields[1]) - assert.Equal(t, cadence.NewOptional(nil), blockNumberTrait.Fields[2]) - assert.Equal(t, cadence.NewOptional(nil), blockNumberTrait.Fields[3]) - - mintTrait := traits.Values[1].(cadence.Struct) - mintedTimeDisplayType, _ := cadence.NewString("Date") - assert.Equal(t, mintedTimeName, mintTrait.Fields[0]) - assert.Equal(t, cadence.NewOptional(mintedTimeDisplayType), mintTrait.Fields[2]) - assert.Equal(t, cadence.NewOptional(nil), mintTrait.Fields[3]) - - fooTrait := traits.Values[2].(cadence.Struct) - fooName, _ := cadence.NewString("foo") - fooValue, _ := cadence.NewString("bar") - fooRarityOptional := fooTrait.Fields[3].(cadence.Optional) - fooRarity := fooRarityOptional.Value.(cadence.Struct) - rarityDescription, _ := cadence.NewString("Common") - assert.Equal(t, fooName, fooTrait.Fields[0]) - assert.Equal(t, cadence.NewOptional(fooValue), fooTrait.Fields[1]) - fooRarityScore := fooRarity.Fields[0].(cadence.Optional).Value - score, _ := cadence.NewUFix64("10.0") - assert.Equal(t, fooRarityScore, score) - fooRarityMax := fooRarity.Fields[1].(cadence.Optional).Value - max, _ := cadence.NewUFix64("100.0") - assert.Equal(t, max, fooRarityMax) - assert.Equal(t, fooRarity.Fields[2], cadence.NewOptional(rarityDescription)) - }) -} - func TestSetupCollectionFromNFTReference(t *testing.T) { b, adapter, accountKeys := newTestSetup(t) diff --git a/lib/go/test/nft_test_helpers.go b/lib/go/test/nft_test_helpers.go index 7bddfdc..06ee10a 100644 --- a/lib/go/test/nft_test_helpers.go +++ b/lib/go/test/nft_test_helpers.go @@ -168,7 +168,7 @@ func mintExampleNFT( ) } -// Assers that the ExampleNFT collection in the specified user's account +// Asserts that the ExampleNFT collection in the specified user's account // is the expected length func assertCollectionLength( t *testing.T, diff --git a/transactions/setup_account_to_receive_royalty.cdc b/transactions/setup_account_to_receive_royalty.cdc index 21bc000..5a32e0b 100644 --- a/transactions/setup_account_to_receive_royalty.cdc +++ b/transactions/setup_account_to_receive_royalty.cdc @@ -10,14 +10,13 @@ import "FungibleToken" import "MetadataViews" -import "FlowToken" transaction(vaultPath: StoragePath) { prepare(signer: auth(BorrowValue, IssueStorageCapabilityController, PublishCapability, UnpublishCapability) &Account) { // Return early if the account doesn't have a FungibleToken Vault - if signer.storage.borrow<&FlowToken.Vault>(from: vaultPath) == nil { + if signer.storage.borrow<&{FungibleToken.Receiver}>(from: vaultPath) == nil { panic("A vault for the specified fungible token path does not exist") }