So I have an ERC721 Contract when I mint NFTs then let users clone them but then they get added to the list of tokens, now I need to know if the current user/address owns this NFT? thanks
I assume you are doing this off chain.
First you can check if the address hold any of the token by checking the addresses balance using
You can then loop through the tokens held by the address to get the tokenID using
yes that’s a nice way and i know that but what if the user owns a lot of cloned NFTs? I will have to loop over all of them to find it? for only this tokenid?
I am not sure what you mean by cloned NFTs?
Can you describe your use case a bit more if possible?