Skip to content

fix: exclude deprecated resources from accepts address mapping#974

Merged
onchainlu merged 1 commit into
mainfrom
fix-deprecated-accepts
Jun 10, 2026
Merged

fix: exclude deprecated resources from accepts address mapping#974
onchainlu merged 1 commit into
mainfrom
fix-deprecated-accepts

Conversation

@onchainlu

@onchainlu onchainlu commented Jun 10, 2026

Copy link
Copy Markdown
Contributor

Summary

  • Filters deprecatedAt: null on resourceRel in getAcceptsAddresses so deprecated resources never contribute to the payTo → origin mapping
  • Fixes ghost "+1" origin counts on Featured Services (e.g., StableMerch showing "+1" from stablemerch.dev's deprecated records sharing stableemail.dev's payTo)
  • Fixes inflated transaction stats (StableMerch showing 7.86k txs instead of ~7 — it was inheriting stableemail's stats through the shared deprecated payTo)

Root cause

getAcceptsAddresses only applied the resourceRel filter when tags or originUrls were provided. Without either, no resourceRel filter was set at all, so deprecated resources' accepts records were included. The fix always sets resourceRel: { deprecatedAt: null, ... } regardless of other filters.

Test plan

  • Preview deploy: Featured Services no longer shows "+1" on StableMerch
  • Preview deploy: StableMerch tx count matches actual stats (~7 txs, $115 volume)
  • Spot-check other origins — no active origins disappeared

Deprecated resources' accepts records were polluting the payTo → origin
mapping used by Featured Services. This caused ghost "+1" origin counts
(e.g., StableMerch showing "+1" from stablemerch.dev's deprecated records
sharing stableemail.dev's payTo) and inflated transaction stats (7.86k
instead of 7).

Always filter deprecatedAt: null on the parent resource, not just when
tags or originUrls are provided.
@vercel

vercel Bot commented Jun 10, 2026

Copy link
Copy Markdown
Contributor

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
x402scan Ready Ready Preview, Comment Jun 10, 2026 10:17pm

Request Review

@onchainlu onchainlu merged commit 96000b6 into main Jun 10, 2026
3 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