Skip to content

Commit

Permalink
fix get length
Browse files Browse the repository at this point in the history
  • Loading branch information
fkenji committed Aug 7, 2024
1 parent 09f93a5 commit 672af35
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion contracts/FastBreakV1.cdc
Original file line number Diff line number Diff line change
Expand Up @@ -742,7 +742,7 @@ access(all) contract FastBreakV1: NonFungibleToken {
}

access(all) view fun getLength(): Int {
return self.ownedNFTs.keys.length
return self.ownedNFTs.length
}

init() {
Expand Down
2 changes: 1 addition & 1 deletion contracts/TopShot.cdc
Original file line number Diff line number Diff line change
Expand Up @@ -1083,7 +1083,7 @@ access(all) contract TopShot: NonFungibleToken {

// Return the amount of NFTs stored in the collection
access(all) view fun getLength(): Int {
return self.ownedNFTs.keys.length
return self.ownedNFTs.length
}

// Create an empty Collection for TopShot NFTs and return it to the caller
Expand Down

0 comments on commit 672af35

Please sign in to comment.