Skip to content

cleanup: remove leftover debug console.log in Stripe checkout route #182

Closed

Description

@gkhngyk

Problem

A debug console.log was left in the Stripe checkout route. It fires on every checkout-session creation and just prints the app URL — pure noise in the function logs of a payment path.

web/src/app/api/stripe/checkout/route.ts#L65:

const appUrl = process.env.NEXT_PUBLIC_APP_URL || 'http://localhost:3000';

console.log('appUrl', appUrl);   // ← remove this line

const session = await stripe.checkout.sessions.create({ ... });

Fix

Delete the single debug line:

  const appUrl = process.env.NEXT_PUBLIC_APP_URL || 'http://localhost:3000';
-
-    console.log('appUrl', appUrl);

  const session = await stripe.checkout.sessions.create({

Leave the two console.error(...) calls in the file (lines 28 and 82) — those are intentional error logging and should stay.

Acceptance criteria

  • The console.log('appUrl', appUrl) line is gone.
  • The console.error calls in the same file are untouched.
  • yarn lint + yarn tsc --noEmit clean from web/.

Activity

  1. added
    enhancement
    good first issue
    on Jun 7, 2026
  2. krishnaprasharkp commented on Jun 7, 2026

    @krishnaprasharkp
    Contributor

    Hi! I'd like to work on this issue. Could you please assign it to me?

  3. krishnaprasharkp commented on Jun 8, 2026

    @krishnaprasharkp
    Contributor

    Thanks for the review. I checked the current branch and the diff already shows a single blank line between appUrl and const session, but the Prettier check is still failing.

    Could you point me to the exact formatting change expected in route.ts? I'll update it right away.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Labels

enhancementgood first issue

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions