diff --git a/src/pages/checkout/[courseSlug]/[courseProductId]/index.tsx b/src/pages/checkout/[courseSlug]/[courseProductId]/index.tsx index 3082386..e1d7879 100644 --- a/src/pages/checkout/[courseSlug]/[courseProductId]/index.tsx +++ b/src/pages/checkout/[courseSlug]/[courseProductId]/index.tsx @@ -73,6 +73,8 @@ const useStripe = ( const {error: submitError} = await elements.submit() if (submitError) { setIsSubmitting(false) + onStripeError(submitError.message || 'Nastala neočakávaná chyba') + return } const {error} = await stripe.confirmPayment({