Burned NFT items still appear in NFTOwners Table


I’ve noticed that burned NFTs still appear in the NFTOwners table against the owner immediately before the burn. My server is https://txrxagiqjwro.moralis.io:2053/server and if you need an example checkout item with object ID hFgJwig3xCeLbVjTZ0hxw8pH in BSCNFTOwners.

Would it be possible to pickup these burn events, and either delete the table item, or set the owner to the 0x address maybe?


I have the same issue, but on ETH not BSC. Since the beginning of Moralis we’ve had trouble with burn, sometimes it works (removes them from NTFOwners) and sometimes broken again. Maybe because the table names changed, but it seems that this feature is rarily used or checked by others.
I’m still in the process of releasing a new version to Ropsten and will check it there. Will try to contact the team on Discord if the problem persists.

Hi @keyoke ,

It would be helpful if you show your code as well so that I can push this issue to the core devs and ask for their suggestions.

@matiyin, Could you please follow up with your findings. The more information the better. It will help us investigate better.

Thanks. :slight_smile:

Hi Malik and Matiyin!

Yes sure, though I am not sure it will help that much. The code I have that retrieves NFT is in a cloud function:

queryBountyItems.equalTo("token_address", BOUNTY_TOKEN_ADDRESS); 
const queryResultsBountyItems = await queryBountyItems.find();`Preformatted text`

That is just returning the items for that address from the moralis table. To burn the NFTs I am just calling burn on a contract that inherits from the openzeppelin burn method. I guess I could try a transfer to the 0x address rather than calling burn to see if that is something that moralis consistently picks up?


Here’s an example on https://u5h7yyyil52x.moralis.io:2053/server (v0.0.236)

I’ve called Burn on a ERC721 on BSC, as can be seen in the database in BscNFTTransfers:
ObjectId “YO2KvjkdbjXqTzggHMWCFUVv” tokenId “5” and TX “0xb0c829bbe27a64fe679148e1cc36e10034e75c70da9c38da5a86caab28afe044”

See https://testnet.bscscan.com/tx/0xb0c829bbe27a64fe679148e1cc36e10034e75c70da9c38da5a86caab28afe044 that the token was succesfully burned to a null address.

You can see in BscNFTOwners that tokenId 5 is still there, but should have been removed by the burn event.

I’m sure the same issue with EthNFTOwners exists.

I’ve been in contact with Gerardo Bastidas some months ago about the same issue. It was fixed, then broken again. It would be wonderful if this issue is resolved and included in future tests, as it seems to be overlooked. I guess not many people burn their stuff, but I need it as a feature and it currently breaks the app logic.

Let me know if you need more input or I can talk directly to Gerardo on Discord.

Hi @matiyin,

Yes we have understood that this was an issue and we are trying to resolve them as we speak. You can expect a fix in the next release.

Thank you for your patience, @matiyin. Really appreciate you pointing this out for us. :slight_smile:

1 Like

I can confirm the burn issue still exists on BSC and ETH on the updated v0.0.237

Since I’m having issues with this for months, I’m wondering if/how to work around this.
The ‘owner_of’ table in EthNFTOwners does not get updated with a burn transaction to address 0x00…
so I can’t really filter on it either, just to hide burned token from the front end.
This is a core bug where the Moralis db does not reflect the state of the blockchain.

Any idea?