From feffdeedf02fc84acadd54972a0d50baf3755711 Mon Sep 17 00:00:00 2001 From: daledah Date: Mon, 25 Nov 2024 18:43:16 +0700 Subject: [PATCH] fix prettier --- src/libs/actions/IOU.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/libs/actions/IOU.ts b/src/libs/actions/IOU.ts index b2e173ed0b26..6710823df16a 100644 --- a/src/libs/actions/IOU.ts +++ b/src/libs/actions/IOU.ts @@ -7191,7 +7191,7 @@ function submitReport(expenseReport: OnyxTypes.Report) { const optimisticSubmittedReportAction = ReportUtils.buildOptimisticSubmittedReportAction(expenseReport?.total ?? 0, expenseReport.currency ?? '', expenseReport.reportID, adminAccountID); const optimisticNextStep = NextStepUtils.buildNextStep(expenseReport, isSubmitAndClosePolicy ? CONST.REPORT.STATUS_NUM.CLOSED : CONST.REPORT.STATUS_NUM.SUBMITTED); const approvalChain = ReportUtils.getApprovalChain(PolicyUtils.getPolicy(expenseReport?.policyID), expenseReport); - const managerID = approvalChain.at(0); + const managerID = approvalChain.length ? Number(approvalChain.at(0)) : undefined; const optimisticData: OnyxUpdate[] = !isSubmitAndClosePolicy ? [