From f19b9cb8e1740e7ee004bb531175f0f38ff5d95f Mon Sep 17 00:00:00 2001 From: Allan Carr Date: Tue, 7 Oct 2025 10:59:10 -0700 Subject: [PATCH] IO-3395 Postback Payment Date Signed-off-by: Allan Carr --- server/intellipay/lib/handleCommentBasedPayment.js | 2 +- server/intellipay/lib/handleInvoiceBasedPayment.js | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/server/intellipay/lib/handleCommentBasedPayment.js b/server/intellipay/lib/handleCommentBasedPayment.js index b6f503d33..fd2ff3ef8 100644 --- a/server/intellipay/lib/handleCommentBasedPayment.js +++ b/server/intellipay/lib/handleCommentBasedPayment.js @@ -49,7 +49,7 @@ const handleCommentBasedPayment = async (values, decodedComment, logger, logMeta type: getPaymentType(ipMapping, values.cardtype), jobid: p.jobid, date: moment() - .tz(bodyshop.bodyshops_by_pk.timezone || "UTC") + .tz(bodyshop?.bodyshops_by_pk?.timezone ?? "UTC") .format("YYYY-MM-DD"), payment_responses: { data: { diff --git a/server/intellipay/lib/handleInvoiceBasedPayment.js b/server/intellipay/lib/handleInvoiceBasedPayment.js index 2279a9da5..34a1a5e8d 100644 --- a/server/intellipay/lib/handleInvoiceBasedPayment.js +++ b/server/intellipay/lib/handleInvoiceBasedPayment.js @@ -98,7 +98,7 @@ const handleInvoiceBasedPayment = async (values, logger, logMeta, res) => { type: getPaymentType(ipMapping, values.cardtype), jobid: job.id, date: moment() - .tz(bodyshop.timezone || "UTC") + .tz(bodyshop?.timezone ?? "UTC") .format("YYYY-MM-DD") } });