You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
PR #2010 introduced `shareableUrl(path)` in `src/utils/url.utils.ts` and migrated the receipt + history + invite + payment-request link builders so a share copied from staging stays on staging (was: silently rewritten to peanut.me whenever `NEXT_PUBLIC_BASE_URL` wasn't set).
The simplify-pass reviewer turned up ~8 other call sites with the same bug class. They were scoped out of #2010 to keep the PR focused but should follow as a sweep.
What to migrate
All construct user-shareable URLs from `BASE_URL` (or `process.env.NEXT_PUBLIC_BASE_URL`) and should use `shareableUrl(path)` instead:
`src/components/Create/useCreateLink.tsx:107` — `/claim` link
`src/components/Badges/BadgeStatusDrawer.tsx:31` — profile share link
`src/components/Global/DirectSendQR/index.tsx:191` — `/pay/` QR target
Context
PR #2010 introduced `shareableUrl(path)` in `src/utils/url.utils.ts` and migrated the receipt + history + invite + payment-request link builders so a share copied from staging stays on staging (was: silently rewritten to peanut.me whenever `NEXT_PUBLIC_BASE_URL` wasn't set).
The simplify-pass reviewer turned up ~8 other call sites with the same bug class. They were scoped out of #2010 to keep the PR focused but should follow as a sweep.
What to migrate
All construct user-shareable URLs from `BASE_URL` (or `process.env.NEXT_PUBLIC_BASE_URL`) and should use `shareableUrl(path)` instead:
What NOT to touch (legitimately server/build-baked)
Acceptance
Related