mirror of
https://github.com/jcreek/SvelteKitSaasBoilerplate.git
synced 2026-07-12 18:43:50 +00:00
fix(#45): Remove customer creation from subscription checkout mode
This commit is contained in:
@@ -50,10 +50,6 @@ export const POST: RequestHandler = async ({ request, cookies, locals: { safeGet
|
||||
if (stripeCustomerId) {
|
||||
// If the user has a Stripe customer ID, attach it to the checkout session
|
||||
stripeCheckoutSessionObject.customer = stripeCustomerId;
|
||||
} else {
|
||||
// If the user doesn't have a Stripe customer ID, create a new customer
|
||||
stripeCheckoutSessionObject.customer_creation = 'always';
|
||||
stripeCheckoutSessionObject.customer_email = userEmail;
|
||||
}
|
||||
|
||||
// Create a subscription checkout session with Stripe
|
||||
|
||||
Reference in New Issue
Block a user