fix: return response for failed invoices

This commit is contained in:
Mythie
2023-10-25 13:29:00 +11:00
parent f68b65fe5f
commit a975509923

View File

@ -230,6 +230,11 @@ export const stripeWebhookHandler = async (
}
await onSubscriptionUpdated({ userId: result.userId, subscription });
return res.status(200).json({
success: true,
message: 'Webhook received',
});
})
.with('customer.subscription.deleted', async () => {
// eslint-disable-next-line @typescript-eslint/consistent-type-assertions