Skip to content

Commit

Permalink
Merge pull request #37392 from dukenv0307/fix/37346
Browse files Browse the repository at this point in the history
Get correct default category for split scan request
  • Loading branch information
puneetlath committed Feb 28, 2024
2 parents b384904 + dd6703a commit 19faec9
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/pages/iou/request/step/IOURequestStepCategory.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import lodashGet from 'lodash/get';
import lodashIsEmpty from 'lodash/isEmpty';
import PropTypes from 'prop-types';
import React from 'react';
import {withOnyx} from 'react-native-onyx';
Expand Down Expand Up @@ -72,7 +73,7 @@ function IOURequestStepCategory({
const {translate} = useLocalize();
const isEditing = action === CONST.IOU.ACTION.EDIT;
const isEditingSplitBill = isEditing && iouType === CONST.IOU.TYPE.SPLIT;
const {category: transactionCategory} = ReportUtils.getTransactionDetails(isEditingSplitBill ? splitDraftTransaction : transaction);
const {category: transactionCategory} = ReportUtils.getTransactionDetails(isEditingSplitBill && !lodashIsEmpty(splitDraftTransaction) ? splitDraftTransaction : transaction);

const isPolicyExpenseChat = ReportUtils.isGroupPolicy(report);
// eslint-disable-next-line rulesdir/no-negated-variables
Expand Down

0 comments on commit 19faec9

Please sign in to comment.