Skip to content

Commit 06dc11c

Browse files
looplabs-funclaude
andcommitted
fix(hood): $LOOP's page offered a Buy button that could only revert
Production had NEXT_PUBLIC_HOOD_LAUNCHER_ADDRESS set, so HoodSwapCard rendered its full "Amount in ETH" buy/sell form — quoting OUR HoodLauncher bonding curve for a token that launched on Pons. The curve read returns nothing for a token it doesn't hold, so the form quoted garbage and any trade would have reverted. That env var says the launcher contract exists; it never said this token is on it. The previous commit's honest-Pons state was unreachable behind it. The launcher path now also requires the token NOT be a Pons launch, so Pons tokens fall through to the live-on-Hood state that points at paths that work. Verified locally with the launcher env set (reproducing production): the buy form is gone and the Pons state renders. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
1 parent 400a794 commit 06dc11c

1 file changed

Lines changed: 6 additions & 1 deletion

File tree

components/token/HoodSwapCard.tsx

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,8 +29,13 @@ export function HoodSwapCard({ project: p }: { project: Project }) {
2929
// swap route to it yet. Conflating the two is what made a launched token
3030
// announce "trading opens when the Hood launcher goes live" on its own page,
3131
// hours after it started trading.
32-
const deployed = !!hoodLauncherAddress();
3332
const onPons = /pons/i.test(p.launchpad ?? "") && !!token;
33+
// ...and it must be a token OUR launcher actually holds. NEXT_PUBLIC_HOOD_-
34+
// LAUNCHER_ADDRESS being set says the contract exists, NOT that this token is
35+
// on it. $LOOP launched on Pons while that env var was set, so production
36+
// rendered a full "Amount in ETH" buy form that quoted the wrong contract —
37+
// a Buy button that could only ever revert.
38+
const deployed = !!hoodLauncherAddress() && !onPons;
3439

3540
const [side, setSide] = useState<"buy" | "sell">("buy");
3641
const [payWith, setPayWith] = useState<"eth" | "sol">("eth");

0 commit comments

Comments
 (0)