The ID emitted in the NFT_Dealers_Listed event should be the same ID used to interact with the listing (e.g., in buy() or cancelListing()).
The event emits an incrementing listingsCounter, but the protocol functions expect the tokenId. Since users can list tokens in any order (e.g., listing Token #5 first), these two IDs will drift apart immediately.
Likelihood:
Any integration (UI, Bot, Indexer) that listens for NFT_Dealers_Listed will receive an ID that is invalid for the buy() function if the token being listed is not the Nth token minted.
Impact:
User experience breakdown: Users see "Listing #1" in the UI, but calling buy(1) either fails or buys the wrong NFT.
Protocol functions like buy, cancelListing, and updatePrice become essentially unusable via standard event-driven interfaces.
Standardize the indexing. Either use listingsCounter as the key for the s_listings mapping (allowing a token to be listed multiple times) or emit the _tokenId in the event instead of the counter.
The contest is live. Earn rewards by submitting a finding.
This is your time to appeal against judgements on your submissions.
Appeals are being carefully reviewed by our judges.
The contest is complete and the rewards are being distributed.