The modern link attribution platform. Loved by world-class engineering teams at Twilio, Zillow, Jobber, Vercel, Raycast, and more.
TypeScript clickhousemysqlnextjsopen-sourceplanetscaleprismatailwindcsstinybirdtypescriptupstashvercel
remove stripe error logs
Steven Tey7cfdb5eba70b
diff --git a/apps/web/app/api/stripe/webhook/customer-subscription-deleted.ts b/apps/web/app/api/stripe/webhook/customer-subscription-deleted.tsindex 89b38838f8..eea4d12e33 100644--- a/apps/web/app/api/stripe/webhook/customer-subscription-deleted.ts+++ b/apps/web/app/api/stripe/webhook/customer-subscription-deleted.ts@@ -56,13 +56,11 @@ export async function customerSubscriptionDeleted(event: Stripe.Event) {});if (!workspace) {- await log({- message:- "Workspace with Stripe ID *`" ++ console.log(+ "Workspace with Stripe ID *`" +stripeId +"`* not found in Stripe webhook `customer.subscription.deleted` callback",- type: "errors",- });+ );return NextResponse.json({ received: true });}diff --git a/apps/web/app/api/stripe/webhook/customer-subscription-updated.ts b/apps/web/app/api/stripe/webhook/customer-subscription-updated.tsindex bab371df9b..58686ed214 100644--- a/apps/web/app/api/stripe/webhook/customer-subscription-updated.ts+++ b/apps/web/app/api/stripe/webhook/customer-subscription-updated.ts@@ -51,13 +51,11 @@ export async function customerSubscriptionUpdated(event: Stripe.Event) {});if (!workspace) {- await log({- message:- "Workspace with Stripe ID *`" ++ console.log(+ "Workspace with Stripe ID *`" +stripeId +"`* not found in Stripe webhook `customer.subscription.updated` callback",- type: "errors",- });+ );return NextResponse.json({ received: true });}diff --git a/apps/web/app/api/stripe/webhook/invoice-payment-failed.tsx b/apps/web/app/api/stripe/webhook/invoice-payment-failed.tsxindex e4a5a5ad43..ceccf53a92 100644--- a/apps/web/app/api/stripe/webhook/invoice-payment-failed.tsx+++ b/apps/web/app/api/stripe/webhook/invoice-payment-failed.tsx@@ -1,7 +1,6 @@import { sendEmail } from "@dub/email";import { FailedPayment } from "@dub/email/templates/failed-payment";import { prisma } from "@dub/prisma";-import { log } from "@dub/utils";import Stripe from "stripe";export async function invoicePaymentFailed(event: Stripe.Event) {@@ -12,10 +11,11 @@ export async function invoicePaymentFailed(event: Stripe.Event) {} = event.data.object as Stripe.Invoice;if (!stripeId) {- await log({- message: "Missing customer ID in invoice.payment_failed event",- type: "errors",- });+ console.log(+ "Invoice with Stripe ID *`" ++ stripeId ++ "`* not found in invoice.payment_failed event",+ );return;}@@ -46,10 +46,11 @@ export async function invoicePaymentFailed(event: Stripe.Event) {});if (!workspace) {- await log({- message: `Project with Stripe ID ${stripeId} not found in invoice.payment_failed event`,- type: "errors",- });+ console.log(+ "Workspace with Stripe ID *`" ++ stripeId ++ "`* not found in invoice.payment_failed event",+ );return;}