You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[Due for payment 2026-05-20] [$250] Broken report page and report review after removing split #87094
Version Number: 9.3.52-0 Reproducible in staging?: Y Reproducible in production?: Y If this was caught during regression testing, add the test name, ID and link from BrowserStack: Email or phone of affected tester (no customers): Logs:https://stackoverflow.com/c/expensify/questions/4856 Expensify/Expensify Issue URL: Issue reported by:@jnowakow Slack conversation (hyperlinked to channel name): #Expensify Bugs
Action Performed:
Navigate to workspace chat and create report
Add expense
Split expense from step 2
Open one of child expenses
Click More > Edit splits
Select one split
Remove split
Expected Result:
Report should have expense details.
Actual Result:
Report page shows only amount. Preview is empty.
Workaround:
Unknown
Platforms:
Select the officially supported platforms where the issue was reproduced:
When a split is removed via "Edit splits" → "Remove split", the updateSplitTransactions function in Split.ts handles two paths: UPDATE (2+ splits remain) and REVERT (1 split remains). Both paths have a gap in how they update the report preview.
UPDATE path (Split.ts:1930-1949): The original IOU action (firstIOU) in the expense report is optimistically deleted — its message.html is set to '', IOUTransactionID to null, and pendingAction to DELETE. The REPORT_PREVIEW action is updated via pushUpdatedReportPreviewActionToOnyxData (Split.ts:1221-1246), but this only updates metadata (childVisibleActionCount, childCommenterCount, etc.) — it does not update the preview's message text or amount.
When getReportPreviewMessage (ReportUtils.ts:5380-5384) runs, it calls getLinkedTransaction(iouReportAction) to build the preview text. Since the deleted IOU action has IOUTransactionID: null, getLinkedTransaction returns empty, and the function falls back to reportActionMessage — which is also empty ('') because the action's message HTML was cleared. This produces the empty preview.
For the report page itself, getDeleteTrackExpenseInformation (IOU/index.ts:3041-3059) sets the deleted child transaction to null in Onyx and its report action message to empty. This breaks the report page display for the deleted expense row, showing only the amount (from the report total) with no transaction details.
REVERT path (Split.ts:2003-2066): The expense report is deleted (reportID: null) but — unlike the equivalent code in Search.ts:1063-1091 which properly marks the REPORT_PREVIEW action with pendingAction: DELETE — the Split.ts revert path does not mark the REPORT_PREVIEW for deletion. This leaves a REPORT_PREVIEW action pointing to a null/empty report, causing getReportPreviewMessage to hit the empty-report fallback at ReportUtils.ts:5373.
What changes do you think we should make in order to solve the problem?
Update the REPORT_PREVIEW message content during split updates: In updateSplitTransactions (Split.ts), after processing split removals, update the REPORT_PREVIEW action's message field (not just metadata) with the correct preview text reflecting the new report total and remaining transactions. This mirrors what deleteMoneyRequest does at IOU/index.ts:8140-8162 where it explicitly recomputes the preview message text using translateLocal('iou.payerOwesAmount', ...) and updates childMoneyRequestCount.
Mark REPORT_PREVIEW for deletion in the revert path: In the reverse-split path (Split.ts:2003-2066), when isLastTransactionInReport is true, add pendingAction: DELETE to the REPORT_PREVIEW action — consistent with how Search.ts:1063-1091 handles the same operation.
What alternative solutions did you explore? (Optional)
An alternative would be to make getReportPreviewMessage more resilient to empty/deleted IOU actions by falling through to the report.total-based message earlier (before trying getLinkedTransaction). However, this would be a workaround that masks the real problem — the optimistic data should accurately represent the post-removal state so the UI renders correctly without needing extra fallback logic.
Next Steps for Contributor+ team: Reply with @MelvinBot implement this to create a draft PR, @MelvinBot <your feedback> to refine this analysis, or explain why you are rejecting Melvin's proposal.
changed the title [-]Broken report page and report review after removing split[/-][+][$250] Broken report page and report review after removing split[/+]on Apr 3, 2026
Please re-state the problem that we are trying to solve in this issue.
After removing a split expense via "Edit splits" → "Remove split", the report page shows only the amount with no expense details, and the report preview in the chat is empty/broken.
What is the root cause of that problem?
The root cause is in src/libs/actions/IOU/Split.ts in the updateSplitTransactionsFromSplitExpensesFlow function. When a split is removed (non-reverse UPDATE path, ~line 1858-1905), the firstIOU report action is optimistically deleted — its message.html is set to '' and IOUTransactionID is set to null. However, the REPORT_PREVIEW action's message text is never updated to reflect the new report total.
Here's why:
getCleanUpTransactionThreadReportOnyxData is called with shouldAddUpdatedReportPreviewActionToOnyxData: false (line 1826), so it only returns updated metadata fields (childVisibleActionCount, childCommenterCount, etc.) without pushing them to Onyx.
pushUpdatedReportPreviewActionToOnyxData() (line 1905) is only called in the else branch — when firstIOU does NOT exist. When firstIOU exists and is deleted, it's skipped.
The pushUpdatedReportPreviewActionToOnyxData function itself (line 1219-1246) only pushes metadata fields from updateOptimisticParentReportAction — it never updates the message text of the REPORT_PREVIEW action.
The result: when getReportPreviewMessage (src/libs/ReportUtils.ts:5380) runs, it calls getLinkedTransaction(iouReportAction) to build the preview text. Since the deleted IOU action has IOUTransactionID: null, getLinkedTransaction returns empty. The function falls back to reportActionMessage, which is also empty because the action's message HTML was cleared. This produces the blank preview.
Compare this with deleteMoneyRequest in src/libs/actions/IOU/index.ts (lines 8134-8157), which correctly recomputes the REPORT_PREVIEW message text:
constmessageText=Localize.translateLocal(hasNonReimbursableTransactions ? 'iou.payerSpentAmount' : 'iou.payerOwesAmount',convertToDisplayString(updatedIOUReport?.total,updatedIOUReport?.currency),getPersonalDetailsForAccountID(updatedIOUReport?.managerID??CONST.DEFAULT_NUMBER_ID).login??'',);// Then updates updatedReportPreviewAction.message with the new text
And also decrements childMoneyRequestCount. The split removal path does neither of these.
Note: MelvinBot's claim that the REVERT path "does not mark the REPORT_PREVIEW for deletion" is incorrect — it does so via expenseReport.parentReportActionID at ~line 1965-1980. The actual bug is in the UPDATE path's failure to update the preview message text.
What changes do you think we should make in order to solve the problem?
Update the REPORT_PREVIEW message text after split removal — In src/libs/actions/IOU/Split.ts, after the firstIOU branch (~line 1900), update the REPORT_PREVIEW action's message field with the recomputed preview text reflecting the new report total. This should mirror what deleteMoneyRequest does in src/libs/actions/IOU/index.ts:8134-8157:
// After line ~1900 in Split.ts, inside the `if (firstIOU)` block, after pushing the updatedReportAction:constreportTotal=reportTotals.get(expenseReportID)??0;consthasNonReimbursableTransactions=hasNonReimbursableTransactionsReportUtils(expenseReport?.reportID);constmessageText=Localize.translateLocal(hasNonReimbursableTransactions ? 'iou.payerSpentAmount' : 'iou.payerOwesAmount',convertToDisplayString(reportTotal,expenseReport?.currency),getPersonalDetailsForAccountID(expenseReport?.managerID??CONST.DEFAULT_NUMBER_ID).login??'',);if(updatedReportPreviewAction&&originalReportPreviewAction){if(Array.isArray(updatedReportPreviewAction?.message)){constmessage=updatedReportPreviewAction.message.at(0);if(message){message.text=messageText;message.html=messageText;}}elseif(updatedReportPreviewAction.message){updatedReportPreviewAction.message.text=messageText;}}
Decrement childMoneyRequestCount on the REPORT_PREVIEW — Also update the report preview's childMoneyRequestCount to reflect the removed expense:
Push the updated REPORT_PREVIEW to Onyx — After updating the message and count, call pushUpdatedReportPreviewActionToOnyxData() (removing it from the else branch so it's called in both paths).
What alternative solutions did you explore? (Optional)
An alternative would be to make getReportPreviewMessage in ReportUtils.ts more resilient — when the linked IOU action has a null IOUTransactionID, fall back to building the message from the report's total rather than returning empty. While this would fix the display issue, it's a band-aid: the optimistic data should accurately represent the post-removal state. The deleteMoneyRequest flow already established the correct pattern of recomputing the preview message text — the split removal flow should follow the same pattern for consistency and correctness. Fixing it at the source also ensures the Onyx data is correct for any other consumers beyond just getReportPreviewMessage.
When we remove a split from More > Edit splits, the split edit flow updates the parent report preview action through getCleanUpTransactionThreadReportOnyxData(). In that helper, the preview action is rebuilt with only child-count metadata. That partial object is then written back to the report action collection for the same reportActionID, so the existing preview message payload is lost. Once message is missing, the report row can still show amount totals but cannot render preview text, which is why the preview appears empty.
What changes do you think we should make in order to solve the problem?
We should preserve the existing preview action fields (especially message) when updating child counters, instead of replacing the whole action object with a reduced shape.
⚠️@abbasifaizan70 Your proposal is a duplicate of an already existing proposal and has been automatically withdrawn to prevent spam. Please review the existing proposals before submitting a new one.
Please re-state the problem that we are trying to solve in this issue.
After removing a split from a 2-split expense (which triggers a reverse-split operation), the report page only shows the amount without transaction details, and the report preview renders empty.
What is the root cause of that problem?
The root cause is in the reverse-split path of updateSplitTransactions in Split.ts. When the number of splits drops from 2 to 1, the code takes the isReverseSplitOperation path. This path has two bugs that break both the report page and the preview:
In the reverse-split path, requestMoneyInformation.existingTransaction is set to undefined. This causes getMoneyRequestInformation to skip the fastMerge path that would normally copy the original transaction's data (merchant, category, receipt, comment, etc.) into the optimistic transaction. Without this merge, the reverted transaction is created with incomplete data, which is why the report page shows only the amount (the transaction exists but lacks detail fields).
2. currentReportActionID is set to undefined for the reverse-split path:
The ternary !isReverseSplitOperation ? currentReportAction?.reportActionID : undefined passes undefined when isReverseSplitOperation is true. This causes getMoneyRequestInformation to create a brand-new duplicate IOU action in the expense report instead of reusing firstIOU. The original firstIOU remains but is now orphaned from the new transaction flow, leading to the empty preview because the report preview action points to the wrong IOU action chain.
What changes do you think we should make in order to solve the problem?
Remove the existingTransaction = undefined assignment (line 1335) so the original transaction reference is preserved and getMoneyRequestInformation properly merges the original data into the optimistic transaction.
Pass firstIOU?.reportActionID as currentReportActionID in the reverse-split path (line 1359), changing from:
What alternative solutions did you explore? (Optional)
One alternative is to update the returned reportPreviewAction in getCleanUpTransactionThreadReportOnyxData (line 8575) to spread the full original action object. However, since pushUpdatedReportPreviewActionToOnyxData uses Onyx.METHOD.MERGE (not SET), existing fields like message are already preserved in the Onyx store. The preview is empty not because the message field is lost, but because the underlying transaction and IOU action chain is broken by the two bugs described above.
Please re-state the problem that we are trying to solve in this issue.
After removing a split from a split expense via "Edit splits", the expense report page displays incorrectly (showing only the total amount without proper expense details) and the report preview card in the chat appears broken/empty.
What is the root cause of that problem?
When a split is removed through the delete flow, useDeleteTransactions.ts calls updateSplitTransactions without providing the splitExpensesTotal field in transactionData. This value is critical for correctly computing the new expense report total.
What changes do you think we should make in order to solve the problem?
We should compute splitExpensesTotal from all child transactions (before filtering out the ones being deleted) and pass it in the transactionData parameter. The fix is in useDeleteTransactions.ts:
// In useDeleteTransactions.ts, before the updateSplitTransactions call (~line 148):constallChildTransactionsForTotal=getChildTransactions(allTransactions,allReports,transactionID);constsplitExpensesTotal=allChildTransactionsForTotal.reduce((total,tx)=>total+Math.abs(tx?.amount??0),0);updateSplitTransactions({// ... existing params ...transactionData: {reportID: report?.reportID??String(CONST.DEFAULT_NUMBER_ID),originalTransactionID: transactionID,splitExpenses: remainingSplitExpenses,
splitExpensesTotal,// Add this missing field},// ... rest of params ...});
This ensures the expense report total is correctly adjusted to reflect only the remaining splits, fixing the broken report display and preview rendering.
[Contributor] The offending PR has been commented on, pointing out the bug it caused and why, so the author and reviewers can learn from the mistake.
Link to comment: No offending frontend PR — this was caused by a backend change (Expensify/Auth#19931) that modified deleteMoneyRequest() to preserve IOUTransactionID, which broke the split removal flow. Identified by @lakchotehere.
[Contributor] If the regression was CRITICAL (e.g. interrupts a core flow) A discussion in #expensify-open-source has been started about whether any other steps should be taken (e.g. updating the PR review checklist) in order to catch this type of bug sooner.
Link to discussion: N/A
[Contributor] If it was decided to create a regression test for the bug, please propose the regression test steps using the template below to ensure the same bug will not reach production again.
[BugZero Assignee] Create a GH issue for creating/updating the regression test once above steps have been agreed upon.
Contributor: @paulnjs paid $250 via Upwork
Contributor+: @Krishna2323 due $250 via NewDot
@paulnjs can you please accept the job below? Please reply here and tag me once you have.
If you're not sent an offer in Upwork when you're assigned to an issue, and an Upwork job exists, please submit a proposal. https://www.upwork.com/jobs/~022059080203273242542
Activity
MelvinBot commentedon Apr 3, 2026
Proposal
What is the root cause of that problem?
When a split is removed via "Edit splits" → "Remove split", the
updateSplitTransactionsfunction inSplit.tshandles two paths: UPDATE (2+ splits remain) and REVERT (1 split remains). Both paths have a gap in how they update the report preview.UPDATE path (
Split.ts:1930-1949): The original IOU action (firstIOU) in the expense report is optimistically deleted — itsmessage.htmlis set to'',IOUTransactionIDtonull, andpendingActiontoDELETE. The REPORT_PREVIEW action is updated viapushUpdatedReportPreviewActionToOnyxData(Split.ts:1221-1246), but this only updates metadata (childVisibleActionCount,childCommenterCount, etc.) — it does not update the preview's message text or amount.When
getReportPreviewMessage(ReportUtils.ts:5380-5384) runs, it callsgetLinkedTransaction(iouReportAction)to build the preview text. Since the deleted IOU action hasIOUTransactionID: null,getLinkedTransactionreturns empty, and the function falls back toreportActionMessage— which is also empty ('') because the action's message HTML was cleared. This produces the empty preview.For the report page itself,
getDeleteTrackExpenseInformation(IOU/index.ts:3041-3059) sets the deleted child transaction tonullin Onyx and its report action message to empty. This breaks the report page display for the deleted expense row, showing only the amount (from the report total) with no transaction details.REVERT path (
Split.ts:2003-2066): The expense report is deleted (reportID: null) but — unlike the equivalent code inSearch.ts:1063-1091which properly marks the REPORT_PREVIEW action withpendingAction: DELETE— the Split.ts revert path does not mark the REPORT_PREVIEW for deletion. This leaves a REPORT_PREVIEW action pointing to a null/empty report, causinggetReportPreviewMessageto hit the empty-report fallback atReportUtils.ts:5373.What changes do you think we should make in order to solve the problem?
Update the REPORT_PREVIEW message content during split updates: In
updateSplitTransactions(Split.ts), after processing split removals, update the REPORT_PREVIEW action'smessagefield (not just metadata) with the correct preview text reflecting the new report total and remaining transactions. This mirrors whatdeleteMoneyRequestdoes atIOU/index.ts:8140-8162where it explicitly recomputes the preview message text usingtranslateLocal('iou.payerOwesAmount', ...)and updateschildMoneyRequestCount.Mark REPORT_PREVIEW for deletion in the revert path: In the reverse-split path (
Split.ts:2003-2066), whenisLastTransactionInReportis true, addpendingAction: DELETEto the REPORT_PREVIEW action — consistent with howSearch.ts:1063-1091handles the same operation.What alternative solutions did you explore? (Optional)
An alternative would be to make
getReportPreviewMessagemore resilient to empty/deleted IOU actions by falling through to thereport.total-based message earlier (before tryinggetLinkedTransaction). However, this would be a workaround that masks the real problem — the optimistic data should accurately represent the post-removal state so the UI renders correctly without needing extra fallback logic.Next Steps for Contributor+ team: Reply with
@MelvinBot implement thisto create a draft PR,@MelvinBot <your feedback>to refine this analysis, or explain why you are rejecting Melvin's proposal.melvin-bot commentedon Apr 3, 2026
Triggered auto assignment to Contributor-plus team member for initial proposal review - @Krishna2323 (
External)[-]Broken report page and report review after removing split[/-][+][$250] Broken report page and report review after removing split[/+]melvin-bot commentedon Apr 3, 2026
Job added to Upwork: https://www.upwork.com/jobs/~022040074536357088393
ReaperOAK commentedon Apr 3, 2026
Proposal
Please re-state the problem that we are trying to solve in this issue.
After removing a split expense via "Edit splits" → "Remove split", the report page shows only the amount with no expense details, and the report preview in the chat is empty/broken.
What is the root cause of that problem?
The root cause is in
src/libs/actions/IOU/Split.tsin theupdateSplitTransactionsFromSplitExpensesFlowfunction. When a split is removed (non-reverse UPDATE path, ~line 1858-1905), thefirstIOUreport action is optimistically deleted — itsmessage.htmlis set to''andIOUTransactionIDis set tonull. However, the REPORT_PREVIEW action's message text is never updated to reflect the new report total.Here's why:
getCleanUpTransactionThreadReportOnyxDatais called withshouldAddUpdatedReportPreviewActionToOnyxData: false(line 1826), so it only returns updated metadata fields (childVisibleActionCount,childCommenterCount, etc.) without pushing them to Onyx.pushUpdatedReportPreviewActionToOnyxData()(line 1905) is only called in theelsebranch — whenfirstIOUdoes NOT exist. WhenfirstIOUexists and is deleted, it's skipped.pushUpdatedReportPreviewActionToOnyxDatafunction itself (line 1219-1246) only pushes metadata fields fromupdateOptimisticParentReportAction— it never updates themessagetext of the REPORT_PREVIEW action.The result: when
getReportPreviewMessage(src/libs/ReportUtils.ts:5380) runs, it callsgetLinkedTransaction(iouReportAction)to build the preview text. Since the deleted IOU action hasIOUTransactionID: null,getLinkedTransactionreturns empty. The function falls back toreportActionMessage, which is also empty because the action's message HTML was cleared. This produces the blank preview.Compare this with
deleteMoneyRequestinsrc/libs/actions/IOU/index.ts(lines 8134-8157), which correctly recomputes the REPORT_PREVIEW message text:And also decrements
childMoneyRequestCount. The split removal path does neither of these.Note: MelvinBot's claim that the REVERT path "does not mark the REPORT_PREVIEW for deletion" is incorrect — it does so via
expenseReport.parentReportActionIDat ~line 1965-1980. The actual bug is in the UPDATE path's failure to update the preview message text.What changes do you think we should make in order to solve the problem?
src/libs/actions/IOU/Split.ts, after thefirstIOUbranch (~line 1900), update the REPORT_PREVIEW action'smessagefield with the recomputed preview text reflecting the new report total. This should mirror whatdeleteMoneyRequestdoes insrc/libs/actions/IOU/index.ts:8134-8157:childMoneyRequestCounton the REPORT_PREVIEW — Also update the report preview'schildMoneyRequestCountto reflect the removed expense:pushUpdatedReportPreviewActionToOnyxData()(removing it from theelsebranch so it's called in both paths).What alternative solutions did you explore? (Optional)
An alternative would be to make
getReportPreviewMessageinReportUtils.tsmore resilient — when the linked IOU action has a nullIOUTransactionID, fall back to building the message from the report's total rather than returning empty. While this would fix the display issue, it's a band-aid: the optimistic data should accurately represent the post-removal state. ThedeleteMoneyRequestflow already established the correct pattern of recomputing the preview message text — the split removal flow should follow the same pattern for consistency and correctness. Fixing it at the source also ensures the Onyx data is correct for any other consumers beyond justgetReportPreviewMessage.abbasifaizan70 commentedon Apr 3, 2026
Proposal
What is the root cause of that problem?
When we remove a split from
More > Edit splits, the split edit flow updates the parent report preview action throughgetCleanUpTransactionThreadReportOnyxData(). In that helper, the preview action is rebuilt with only child-count metadata. That partial object is then written back to the report action collection for the samereportActionID, so the existing preview message payload is lost. Oncemessageis missing, the report row can still show amount totals but cannot render preview text, which is why the preview appears empty.App/src/libs/actions/IOU/index.ts
Lines 8574 to 8580 in a718167
App/src/libs/actions/IOU/Split.ts
Lines 1226 to 1231 in a718167
What changes do you think we should make in order to solve the problem?
We should preserve the existing preview action fields (especially
message) when updating child counters, instead of replacing the whole action object with a reduced shape.App/src/libs/actions/IOU/index.ts
Lines 8574 to 8580 in a718167
github-actions commentedon Apr 3, 2026
wildan-m commentedon Apr 3, 2026
Proposal
Please re-state the problem that we are trying to solve in this issue.
After removing a split from a 2-split expense (which triggers a reverse-split operation), the report page only shows the amount without transaction details, and the report preview renders empty.
What is the root cause of that problem?
The root cause is in the reverse-split path of
updateSplitTransactionsinSplit.ts. When the number of splits drops from 2 to 1, the code takes theisReverseSplitOperationpath. This path has two bugs that break both the report page and the preview:1.
existingTransactionis forced toundefined:App/src/libs/actions/IOU/Split.ts
Line 1335 in c76158c
In the reverse-split path,
requestMoneyInformation.existingTransactionis set toundefined. This causesgetMoneyRequestInformationto skip thefastMergepath that would normally copy the original transaction's data (merchant, category, receipt, comment, etc.) into the optimistic transaction. Without this merge, the reverted transaction is created with incomplete data, which is why the report page shows only the amount (the transaction exists but lacks detail fields).2.
currentReportActionIDis set toundefinedfor the reverse-split path:App/src/libs/actions/IOU/Split.ts
Line 1359 in c76158c
The ternary
!isReverseSplitOperation ? currentReportAction?.reportActionID : undefinedpassesundefinedwhenisReverseSplitOperationis true. This causesgetMoneyRequestInformationto create a brand-new duplicate IOU action in the expense report instead of reusingfirstIOU. The originalfirstIOUremains but is now orphaned from the new transaction flow, leading to the empty preview because the report preview action points to the wrong IOU action chain.What changes do you think we should make in order to solve the problem?
Remove the
existingTransaction = undefinedassignment (line 1335) so the original transaction reference is preserved andgetMoneyRequestInformationproperly merges the original data into the optimistic transaction.Pass
firstIOU?.reportActionIDascurrentReportActionIDin the reverse-split path (line 1359), changing from:to:
This reuses the existing IOU action instead of creating a duplicate, keeping the report action chain consistent for the preview.
firstIOUaction on API failure, ensuring proper rollback.Compare branch: https://github.com/Expensify/App/compare/main...wildan-m:App:wildan/87094-fix-broken-report-after-split-removal?expand=1
What alternative solutions did you explore? (Optional)
One alternative is to update the returned
reportPreviewActioningetCleanUpTransactionThreadReportOnyxData(line 8575) to spread the full original action object. However, sincepushUpdatedReportPreviewActionToOnyxDatausesOnyx.METHOD.MERGE(notSET), existing fields likemessageare already preserved in the Onyx store. The preview is empty not because the message field is lost, but because the underlying transaction and IOU action chain is broken by the two bugs described above.trasnake87 commentedon Apr 3, 2026
Proposal
Please re-state the problem that we are trying to solve in this issue.
After removing a split from a split expense via "Edit splits", the expense report page displays incorrectly (showing only the total amount without proper expense details) and the report preview card in the chat appears broken/empty.
What is the root cause of that problem?
When a split is removed through the delete flow,
useDeleteTransactions.tscallsupdateSplitTransactionswithout providing thesplitExpensesTotalfield intransactionData. This value is critical for correctly computing the new expense report total.In
updateSplitTransactions(https://github.com/Expensify/App/blob/main/src/libs/actions/IOU/Split.ts#L1096),splitExpensesTotaldefaults to0when not provided. The report total formula at https://github.com/Expensify/App/blob/main/src/libs/actions/IOU/Split.ts#L1163-L1178 computeschangesInReportTotal = sum(remaining splits) - splitExpensesTotal. WithsplitExpensesTotal = 0, the result is wildly wrong — for example, removing a $40 split from a $100 expense (three splits: $30, $30, $40) yields a report total of -$160 instead of the correct -$60. This corrupted total propagates throughgetMoneyRequestInformationinto the optimistic report data, breaking the expense report display and causing the report preview to render with incorrect state.Other callers like
SplitExpensePage.tsx(https://github.com/Expensify/App/blob/main/src/pages/iou/SplitExpensePage.tsx#L309) correctly passsplitExpensesTotal, confirming this is a missing parameter in the delete flow.What changes do you think we should make in order to solve the problem?
We should compute
splitExpensesTotalfrom all child transactions (before filtering out the ones being deleted) and pass it in thetransactionDataparameter. The fix is inuseDeleteTransactions.ts:This ensures the expense report total is correctly adjusted to reflect only the remaining splits, fixing the broken report display and preview rendering.
63 remaining items
Krishna2323 commentedon May 19, 2026
BugZero Checklist:
[Contributor] The offending PR has been commented on, pointing out the bug it caused and why, so the author and reviewers can learn from the mistake.
Link to comment: No offending frontend PR — this was caused by a backend change (
Expensify/Auth#19931) that modifieddeleteMoneyRequest()to preserveIOUTransactionID, which broke the split removal flow. Identified by @lakchote here.[Contributor] If the regression was CRITICAL (e.g. interrupts a core flow) A discussion in #expensify-open-source has been started about whether any other steps should be taken (e.g. updating the PR review checklist) in order to catch this type of bug sooner.
Link to discussion: N/A
[Contributor] If it was decided to create a regression test for the bug, please propose the regression test steps using the template below to ensure the same bug will not reach production again.
[BugZero Assignee] Create a GH issue for creating/updating the regression test once above steps have been agreed upon.
Link to issue: https://github.com/Expensify/Expensify/issues/640821
Regression Test Proposal
Precondition:
Test:
Do we agree 👍 or 👎
Zapier Logs
Run ID: 00040eee-b538-af84-5f9a-15f5137ce254melvin-bot commentedon May 20, 2026
Payment Summary
Upwork Job
BugZero Checklist (@mallenexpensify)
lakchote commentedon May 25, 2026
Not overdue - this is in the payment and checklist follow-up stage after the fix shipped to production.
mallenexpensify commentedon May 26, 2026
Payment Summary
Contributor: @paulnjs paid $250 via Upwork
Contributor+: @Krishna2323 due $250 via NewDot
@paulnjs can you please accept the job below? Please reply here and tag me once you have.
If you're not sent an offer in Upwork when you're assigned to an issue, and an Upwork job exists, please submit a proposal.
https://www.upwork.com/jobs/~022059080203273242542
^ Test case created. Thx
paulnjs commentedon May 26, 2026
@mallenexpensify I accepted the job. Thanks!
mallenexpensify commentedon May 26, 2026
@paulnjs paid, summary updated above. Thx.
laurenreidexpensify commentedon Jun 29, 2026
$250 approved for @Krishna2323