Skip to content

Conversation

@madisoncarter1234
Copy link
Contributor

Bug

Line 104 in src/sdk.ts uses getOfferPaymentToken() when it should use getListingPaymentToken(). This is a copy-paste error from line 103.

Problem

The wrong token address gets cached for listings. On chains where listing tokens differ from offer tokens (like ETH vs WETH on mainnet), this breaks the cache and could cause issues with listing operations.

Fix

  • Changed line 104 to call getListingPaymentToken(this.chain) instead of getOfferPaymentToken(this.chain)
  • Added the missing import for getListingPaymentToken

The rest of the codebase already uses these functions correctly - this was just a typo in the cache initialization.

The listing payment token cache was incorrectly using getOfferPaymentToken()
instead of getListingPaymentToken(). This caused the wrong token address to
be cached for listings.

This bug could lead to issues when listing payment tokens differ from offer
payment tokens on certain chains.
@ryanio
Copy link
Collaborator

ryanio commented Nov 28, 2025

thanks!

@ryanio ryanio merged commit a640110 into ProjectOpenSea:main Nov 28, 2025
5 of 8 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants