Skip to content

Papermark is the open-source DocSend alternative and secure data rooms with built-in analytics and custom domains.

fix: stripe webhook if subscription id doesn't match

Marc Seitzaf48901cd2d2
diff --git a/pages/api/stripe/webhook.ts b/pages/api/stripe/webhook.ts
index 0cd40c90..2d5597c6 100644
--- a/pages/api/stripe/webhook.ts
+++ b/pages/api/stripe/webhook.ts
@@ -225,7 +225,9 @@ export default async function webhookHandler(
type: "error",
mention: true,
});
- return;
+ return res
+ .status(400)
+ .send(`Error in webhook: ${(error as Error).message}`);
}
} else {
return res.status(400).send(`🤷‍♀️ Unhandled event type: ${event.type}`);