Whoops! 😨 Something unexpected happened...
[Error Code: 1101] error caused by: 1 error occurred:
* transaction execute failed: [Error Code: 1101] cadence runtime error: Execution failed:
error: cannot deploy invalid contract
--> 883a77502b10cb458e1f38df1c9c756b75f02bdd2b1e48510f3bb9266af4ffb5:4:3
|
4 | signer.contracts.add(name: name, code: code.utf8 )
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
error: cannot find type in this scope: `FlowToken`
--> 47d3b365f36b5bd1.ExampleNFT:517:31
|
517 | .capabilities.get<&FlowToken.Vault>(/public/flowTokenReceiver)
| ^^^^^^^^^ not found in this scope
error: cannot infer type parameter: `T`
--> 47d3b365f36b5bd1.ExampleNFT:516:35
|
516 | let treasuryAccountVault = getAccount(ExampleNFT.TreasuryAccount)
517 | .capabilities.get<&FlowToken.Vault>(/public/flowTokenReceiver)
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
error: cannot infer type parameter: `T`
--> 47d3b365f36b5bd1.ExampleNFT:516:35
|
516 | let treasuryAccountVault = getAccount(ExampleNFT.TreasuryAccount)
517 | .capabilities.get<&FlowToken.Vault>(/public/flowTokenReceiver)
518 | .borrow()
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
error: value of type `&Account` has no member `getCapability`
--> 47d3b365f36b5bd1.ExampleNFT:524:13
|
524 | .getCapability<&{NonFungibleToken.CollectionPublic}>(ExampleNFT.CollectionPublicPath)
| ^^^^^^^^^^^^^ unknown member
error: cannot find variable in this scope: `newNFT`
--> 47d3b365f36b5bd1.ExampleNFT:529:45
|
529 | callerCollectionRef.deposit(token: <-newNFT)
| ^^^^^^ not found in this scope
error: missing argument label: `name`
--> 47d3b365f36b5bd1.ExampleNFT:496:16
|
496 | name,
| ^^^^
error: missing argument label: `description`
--> 47d3b365f36b5bd1.ExampleNFT:497:16
|
497 | description,
| ^^^^^^^^^^^
error: missing argument label: `thumbnail`
--> 47d3b365f36b5bd1.ExampleNFT:498:16
|
498 | thumbnail,
| ^^^^^^^^^
error: missing argument label: `royalties`
--> 47d3b365f36b5bd1.ExampleNFT:499:16
|
499 | royalties,
| ^^^^^^^^^
error: missing argument label: `questionID`
--> 47d3b365f36b5bd1.ExampleNFT:500:16
|
500 | questionID,
| ^^^^^^^^^^
error: missing argument label: `side`
--> 47d3b365f36b5bd1.ExampleNFT:501:16
|
501 | side,
| ^^^^
error: missing argument label: `signature`
--> 47d3b365f36b5bd1.ExampleNFT:502:16
|
502 | signature,
| ^^^^^^^^^
error: missing argument label: `salt`
--> 47d3b365f36b5bd1.ExampleNFT:503:16
|
503 | salt
| ^^^^
error: loss of resource
--> 47d3b365f36b5bd1.ExampleNFT:495:12
|
495 | ExampleNFT.mintNFT (
496 | name,
497 | description,
498 | thumbnail,
499 | royalties,
500 | questionID,
501 | side,
502 | signature,
503 | salt
504 | )
| ^
error: missing return statement
--> 47d3b365f36b5bd1.ExampleNFT:491:27
|
491 | ): @ExampleNFT.NFT {
492 |
493 | // Have to place sign verification here
494 |
495 | ExampleNFT.mintNFT (
496 | name,
497 | description,
498 | thumbnail,
499 | royalties,
500 | questionID,
501 | side,
502 | signature,
503 | salt
504 | )
505 |
506 |
507 | }
| ^^^^^^^^^^^^^^^^^^^^^