diff --git a/challenge/index.ts b/challenge/index.ts index c9649b1..884910a 100644 --- a/challenge/index.ts +++ b/challenge/index.ts @@ -13,20 +13,22 @@ The following code will create an instance of the HelloWorldClient and call the There are 2 bugs in the below code. Find and fix them. Hint: Read the Typed clients section in the documentation: https://developer.algorand.org/docs/get-details/algokit/features/generate/?from_query=algokit%20utils#1-typed-clients + */ + const appClient = new HelloWorldClient( { resolveBy: 'creatorAndName', findExistingUsing: indexer, sender: deployer, - creatorAddress: deployer, + creatorAddress: deployer.addr, }, - indexer, + algod, ) await appClient.create.createApplication({}); // TODO: change YOUR_NAME to your name or nickname -const result = await appClient.helloWorld({name: "YOUR_NAME"}, {sendParams: {suppressLog: true}}) +const result = await appClient.helloWorld({name: "Eve"}, {sendParams: {suppressLog: true}}) console.log(result.return) \ No newline at end of file diff --git a/challenge/package-lock.json b/challenge/package-lock.json index d589cb7..c025a57 100644 --- a/challenge/package-lock.json +++ b/challenge/package-lock.json @@ -6,7 +6,7 @@ "": { "name": "challenge-3", "dependencies": { - "@algorandfoundation/algokit-utils": "^5.6.0", + "@algorandfoundation/algokit-utils": "^5.8.0", "@algorandfoundation/tealscript": "^0.88.0", "algosdk": "^2.7.0", "dotenv": "^16.4.4", @@ -17,9 +17,9 @@ } }, "node_modules/@algorandfoundation/algokit-utils": { - "version": "5.6.0", - "resolved": "https://registry.npmjs.org/@algorandfoundation/algokit-utils/-/algokit-utils-5.6.0.tgz", - "integrity": "sha512-VahCNWGG+ICxj1bDbMzFd1IDypUmSrUO+xamcXxrZ8AaKfgkf6xdcE9JRAqIEkIsGXNYXWFA8OVf/ol8u7ohyg==", + "version": "5.8.0", + "resolved": "https://registry.npmjs.org/@algorandfoundation/algokit-utils/-/algokit-utils-5.8.0.tgz", + "integrity": "sha512-BxwUBQ0BaAPpOZt7e2kwP0pfvG2W2AqOBBI6Y3AbJ01a9P7yJ1wIaJfqG02aiG4mpKbLgz84WBQij+0DqGK80Q==", "dependencies": { "buffer": "^6.0.3" }, diff --git a/challenge/package.json b/challenge/package.json index 5448737..c4457fe 100644 --- a/challenge/package.json +++ b/challenge/package.json @@ -5,7 +5,7 @@ "start": "tsx -r dotenv/config index.ts" }, "dependencies": { - "@algorandfoundation/algokit-utils": "^5.6.0", + "@algorandfoundation/algokit-utils": "^5.8.0", "@algorandfoundation/tealscript": "^0.88.0", "algosdk": "^2.7.0", "dotenv": "^16.4.4",