From 1f2fea0c8f7101269f820061e28b32ced9d5d314 Mon Sep 17 00:00:00 2001 From: Kevin Brian Bader Date: Fri, 17 Oct 2025 17:02:18 -0700 Subject: [PATCH] FIX: Unexpected error when unregistered user paying invoice with Business account --- .../MoneyRequestReportPreviewContent.tsx | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/components/ReportActionItem/MoneyRequestReportPreview/MoneyRequestReportPreviewContent.tsx b/src/components/ReportActionItem/MoneyRequestReportPreview/MoneyRequestReportPreviewContent.tsx index b0455b08d87d..779d6a57d838 100644 --- a/src/components/ReportActionItem/MoneyRequestReportPreview/MoneyRequestReportPreviewContent.tsx +++ b/src/components/ReportActionItem/MoneyRequestReportPreview/MoneyRequestReportPreviewContent.tsx @@ -11,6 +11,7 @@ import ButtonWithDropdownMenu from '@components/ButtonWithDropdownMenu'; import {DelegateNoAccessContext} from '@components/DelegateNoAccessModalProvider'; import Icon from '@components/Icon'; import * as Expensicons from '@components/Icon/Expensicons'; +import {PaymentMethod} from '@components/KYCWall/types'; import MoneyReportHeaderStatusBarSkeleton from '@components/MoneyReportHeaderStatusBarSkeleton'; import OfflineWithFeedback from '@components/OfflineWithFeedback'; import {PressableWithFeedback} from '@components/Pressable'; @@ -229,7 +230,7 @@ function MoneyRequestReportPreviewContent({ }, [chatReport, policy, hasReportBeenRetracted, iouReport]); const confirmPayment = useCallback( - (type: PaymentMethodType | undefined, payAsBusiness?: boolean) => { + (type: PaymentMethodType | undefined, payAsBusiness?: boolean, methodID?: number, paymentMethod?: PaymentMethod) => { if (!type) { return; } @@ -242,7 +243,7 @@ function MoneyRequestReportPreviewContent({ } else if (chatReport && iouReport) { startAnimation(); if (isInvoiceReportUtils(iouReport)) { - payInvoice(type, chatReport, iouReport, introSelected, payAsBusiness, existingB2BInvoiceReport, undefined, undefined, activePolicy); + payInvoice(type, chatReport, iouReport, introSelected, payAsBusiness, existingB2BInvoiceReport, methodID, paymentMethod, activePolicy); } else { payMoneyRequest(type, chatReport, iouReport, introSelected, undefined, true, activePolicy); }