Skip to content

Commit cbb96cd

Browse files
Pass backTo to category upgrade path in MoneyRequestView
When editing an expense category from a DM (no workspace), the upgrade path navigation did not pass backTo, causing the RHP to navigate to the wrong tab after creating a category. Pass the category step route with the active route as backTo so navigation returns correctly. Co-authored-by: ahmedGaber93 <ahmedGaber93@users.noreply.github.com>
1 parent 39d1d17 commit cbb96cd

1 file changed

Lines changed: 7 additions & 0 deletions

File tree

src/components/ReportActionItem/MoneyRequestView.tsx

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1055,6 +1055,13 @@ function MoneyRequestView({
10551055
transactionID: transaction.transactionID,
10561056
reportID: transactionThreadReport?.reportID,
10571057
upgradePath: CONST.UPGRADE_PATHS.CATEGORIES,
1058+
backTo: ROUTES.MONEY_REQUEST_STEP_CATEGORY.getRoute(
1059+
CONST.IOU.ACTION.EDIT,
1060+
iouType,
1061+
transaction.transactionID,
1062+
transactionThreadReport?.reportID,
1063+
Navigation.getActiveRoute(),
1064+
),
10581065
}),
10591066
);
10601067
} else if (!policy && shouldSelectPolicy) {

0 commit comments

Comments
 (0)