diff --git a/functions/src/index.ts b/functions/src/index.ts index f8c6544..c5f1c80 100644 --- a/functions/src/index.ts +++ b/functions/src/index.ts @@ -278,7 +278,7 @@ export const createCashfreeOrder = onRequest({ customerPhone: customerPhone, orderStatus: 'CREATED', paymentGateway: 'Cashfree', - createdAt: admin.firestore.FieldValue.serverTimestamp(), + createdAt: new Date(), ...cashfreeResponse.data }); @@ -330,7 +330,7 @@ export const verifyCashfreePayment = onRequest({ await admin.firestore().collection('payment_orders').doc(orderId).update({ orderStatus: cashfreeResponse.data.order_status, paymentDetails: cashfreeResponse.data, - updatedAt: admin.firestore.FieldValue.serverTimestamp() + updatedAt: new Date() }); if (request.headers['x-webhook-source'] === 'cashfree') {