rmrk-substrate icon indicating copy to clipboard operation
rmrk-substrate copied to clipboard

NFT listing

Open mrshiposha opened this issue 3 years ago • 4 comments

One is allowed to partially unlist an NFT via the list extrinsic: https://github.com/rmrk-team/rmrk-substrate/blob/1139b405ce39243da6fca1be062d4ff3cd7f2879/pallets/rmrk-market/src/lib.rs#L255-L260

But this NFT will be locked forever.

I suggest forbidding unlisting through the list extrinsic. I believe that the unlist extrinsic is enough.

mrshiposha avatar Jun 21 '22 16:06 mrshiposha

This is to update the listing if it exists. We could change this to a try_mutate instead on the ListedNfts to prevent the temporary removal from storage.

HashWarlock avatar Jun 28 '22 21:06 HashWarlock

Oh sure, I got confused, sorry :)

mrshiposha avatar Jun 29 '22 10:06 mrshiposha

I believe you can just remove this check because insert will rewrite the value under the key (collectionId, nftId)

mrshiposha avatar Jun 29 '22 10:06 mrshiposha

Agreed we can submit this as a simple refactor.

HashWarlock avatar Jun 30 '22 03:06 HashWarlock