From 6a4cb326e08c7e5720ffc7539212d915d6a77622 Mon Sep 17 00:00:00 2001 From: Jude Zhu Date: Wed, 5 Jun 2024 15:24:15 -0700 Subject: [PATCH] update distribution --- pds/transactions/pds/create_distribution.cdc | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/pds/transactions/pds/create_distribution.cdc b/pds/transactions/pds/create_distribution.cdc index 94fdc96..a89ce36 100644 --- a/pds/transactions/pds/create_distribution.cdc +++ b/pds/transactions/pds/create_distribution.cdc @@ -1,17 +1,17 @@ import PDS from "PDS" -import {{.PackNFTName}} from "PackNFT" +import PackNFT from "PackNFT" import IPackNFT from "IPackNFT" import NonFungibleToken from "NonFungibleToken" -transaction(title: String, metadata: {String: String}) { +transaction(NFTProviderPathIdentifier: string, title: String, metadata: {String: String}) { prepare (issuer: auth(BorrowValue, Capabilities) &Account) { let i = issuer.storage.borrow(from: PDS.PackIssuerStoragePath) ?? panic ("issuer does not have PackIssuer resource") // issuer must have a PackNFT collection - let withdrawCap = issuer.capabilities.storage.issue(StoragePath(identifier: "cadenceExampleNFTCollection")!); - let operatorCap = issuer.capabilities.storage.issue({{.PackNFTName}}.OperatorStoragePath); + let withdrawCap = issuer.capabilities.storage.issue(StoragePath(identifier: NFTProviderPathIdentifier)!); + let operatorCap = issuer.capabilities.storage.issue(PackNFT.OperatorStoragePath); assert(withdrawCap.check(), message: "cannot borrow withdraw capability") assert(operatorCap.check(), message: "cannot borrow operator capability")