From c80fb0c4b43b6d4722386deb34ba4adaadf0fe64 Mon Sep 17 00:00:00 2001 From: Allen T J Date: Tue, 24 Jun 2025 11:53:03 +0000 Subject: [PATCH] phonepe (#63) Co-authored-by: AllenTJ7 <163137620+AllenTJ7@users.noreply.github.com> Reviewed-on: https://git.cosqnet.com/cosqnet/fitlien-services/pulls/63 --- functions/src/payments/phonepe/webhook.ts | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/functions/src/payments/phonepe/webhook.ts b/functions/src/payments/phonepe/webhook.ts index cfb462a..88c9c6f 100644 --- a/functions/src/payments/phonepe/webhook.ts +++ b/functions/src/payments/phonepe/webhook.ts @@ -120,7 +120,7 @@ export const phonePeWebhook = onRequest({ const orderData = orderDoc.data(); const membershipId = orderData.metaInfo?.membershipId; const bookingId = orderData.metaInfo?.bookingId; - const serviceId = orderData.metaInfo?.serviceId; + const paymentId = orderData.metaInfo?.paymentId; if (bookingId) { await processDayPassBooking(payload, orderData, bookingId); @@ -139,8 +139,8 @@ export const phonePeWebhook = onRequest({ if (paymentUpdateSuccess) { await processMembershipPayment(payload, orderData, membershipId); } - } else if (serviceId) { - await processServicePayment(payload, orderData, serviceId); + } else if (paymentId) { + await processServicePayment(payload, orderData, paymentId); } else { logger.error(`No membershipId, bookingId, or serviceId found in metaInfo for order: ${payload.merchantOrderId}`); }