Skip to content

Commit

Permalink
Merge pull request #40239 from shubham1206agra/fix-split-condition
Browse files Browse the repository at this point in the history
Fixed isAllowedToSplit condition

(cherry picked from commit b1b8b4c)
  • Loading branch information
mountiny authored and OSBotify committed Apr 15, 2024
1 parent f1afd48 commit 2b88c50
Showing 1 changed file with 1 addition and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -269,8 +269,7 @@ function MoneyTemporaryForRefactorRequestParticipantsSelector({
const shouldShowSplitBillErrorMessage = participants.length > 1 && hasPolicyExpenseChatParticipant;

// canUseP2PDistanceRequests is true if the iouType is track expense, but we don't want to allow splitting distance with track expense yet
const isAllowedToSplit =
(canUseP2PDistanceRequests || iouRequestType !== CONST.IOU.REQUEST_TYPE.DISTANCE) && (iouType !== CONST.IOU.TYPE.SEND || iouType !== CONST.IOU.TYPE.TRACK_EXPENSE);
const isAllowedToSplit = (canUseP2PDistanceRequests || iouRequestType !== CONST.IOU.REQUEST_TYPE.DISTANCE) && iouType !== CONST.IOU.TYPE.SEND && iouType !== CONST.IOU.TYPE.TRACK_EXPENSE;

const handleConfirmSelection = useCallback(
(keyEvent, option) => {
Expand Down

0 comments on commit 2b88c50

Please sign in to comment.