From 4e8258702ed27bae92f17b836cbed2043a65eced Mon Sep 17 00:00:00 2001 From: Andy Date: Mon, 29 Jul 2024 09:36:17 -0400 Subject: [PATCH] Follow the recommendation that Stripe server wasn't sending shoppingCartId back to the web hook. --- .../Controllers/WebhookController.cs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Modules/OrchardCore.Commerce.Payment.Stripe/Controllers/WebhookController.cs b/src/Modules/OrchardCore.Commerce.Payment.Stripe/Controllers/WebhookController.cs index 3e65cada8..8f5098884 100644 --- a/src/Modules/OrchardCore.Commerce.Payment.Stripe/Controllers/WebhookController.cs +++ b/src/Modules/OrchardCore.Commerce.Payment.Stripe/Controllers/WebhookController.cs @@ -34,7 +34,7 @@ public WebhookController( } [HttpPost] - public async Task Index(string shoppingCartId = null) + public async Task Index() { using var streamReader = new StreamReader(HttpContext.Request.Body); var json = await streamReader.ReadToEndAsync(HttpContext.RequestAborted); @@ -59,7 +59,7 @@ public async Task Index(string shoppingCartId = null) } var paymentIntent = await _stripePaymentService.GetPaymentIntentAsync(paymentIntentId); - await _stripePaymentService.UpdateOrderToOrderedAsync(paymentIntent, shoppingCartId); + await _stripePaymentService.UpdateOrderToOrderedAsync(paymentIntent, shoppingCartId: null); } else if (stripeEvent.Type == Events.PaymentIntentPaymentFailed) {