From 3744ffb0b09958ce205f9e67fdf7617852ab92a1 Mon Sep 17 00:00:00 2001 From: Monil Bhavsar Date: Thu, 6 Jun 2024 11:56:29 +0530 Subject: [PATCH] Fix lint --- src/components/MoneyRequestConfirmationList.tsx | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/components/MoneyRequestConfirmationList.tsx b/src/components/MoneyRequestConfirmationList.tsx index 0db02127af2f..fcb415fc193f 100755 --- a/src/components/MoneyRequestConfirmationList.tsx +++ b/src/components/MoneyRequestConfirmationList.tsx @@ -374,7 +374,6 @@ function MoneyRequestConfirmationList({ let taxableAmount: number; let taxCode: string; if (isDistanceRequest) { - const customUnitRateID = TransactionUtils.getRateID(transaction) ?? ''; const customUnitRate = getCustomUnitRate(policy, customUnitRateID); taxCode = customUnitRate?.attributes?.taxRateExternalID ?? ''; taxableAmount = DistanceRequestUtils.getTaxableAmount(policy, customUnitRateID, TransactionUtils.getDistance(transaction)); @@ -386,7 +385,7 @@ function MoneyRequestConfirmationList({ const taxAmount = TransactionUtils.calculateTaxAmount(taxPercentage, taxableAmount); const taxAmountInSmallestCurrencyUnits = CurrencyUtils.convertToBackendAmount(Number.parseFloat(taxAmount.toString())); IOU.setMoneyRequestTaxAmount(transaction?.transactionID ?? '', taxAmountInSmallestCurrencyUnits); - }, [policy, shouldShowTax, previousTransactionAmount, previousTransactionCurrency, transaction, isDistanceRequest]); + }, [policy, shouldShowTax, previousTransactionAmount, previousTransactionCurrency, transaction, isDistanceRequest, customUnitRateID]); // If completing a split expense fails, set didConfirm to false to allow the user to edit the fields again if (isEditingSplitBill && didConfirm) {