From eb29c7b81931fb397d48d0080b457093d90d7e5f Mon Sep 17 00:00:00 2001 From: Abdelrahman Khattab <59809993+abzokhattab@users.noreply.github.com> Date: Thu, 10 Oct 2024 20:07:43 +0200 Subject: [PATCH 1/2] Fix: App returns to card feed selection page after issuing a card from member profile --- src/pages/workspace/members/WorkspaceMemberNewCardPage.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/pages/workspace/members/WorkspaceMemberNewCardPage.tsx b/src/pages/workspace/members/WorkspaceMemberNewCardPage.tsx index 1b824811d012..7cdfc0fa359d 100644 --- a/src/pages/workspace/members/WorkspaceMemberNewCardPage.tsx +++ b/src/pages/workspace/members/WorkspaceMemberNewCardPage.tsx @@ -81,7 +81,7 @@ function WorkspaceMemberNewCardPage({route, personalDetails}: WorkspaceMemberNew }, isEditing: false, }); - Navigation.navigate(ROUTES.WORKSPACE_EXPENSIFY_CARD_ISSUE_NEW.getRoute(policyID, activeRoute)); + Navigation.navigate(ROUTES.WORKSPACE_EXPENSIFY_CARD_ISSUE_NEW.getRoute(policyID, ROUTES.WORKSPACE_MEMBER_DETAILS.getRoute(policyID, accountID))); } else { CompanyCards.setAssignCardStepAndData({ currentStep: CONST.COMPANY_CARD.STEP.CARD, From f60884a56fe78b011afdf486614e8848b5a7aefd Mon Sep 17 00:00:00 2001 From: Abdelrahman Khattab <59809993+abzokhattab@users.noreply.github.com> Date: Thu, 10 Oct 2024 20:26:46 +0200 Subject: [PATCH 2/2] Fix eslint --- src/pages/workspace/members/WorkspaceMemberNewCardPage.tsx | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/pages/workspace/members/WorkspaceMemberNewCardPage.tsx b/src/pages/workspace/members/WorkspaceMemberNewCardPage.tsx index 7cdfc0fa359d..2c1bb1f66e2d 100644 --- a/src/pages/workspace/members/WorkspaceMemberNewCardPage.tsx +++ b/src/pages/workspace/members/WorkspaceMemberNewCardPage.tsx @@ -72,8 +72,6 @@ function WorkspaceMemberNewCardPage({route, personalDetails}: WorkspaceMemberNew return; } if (selectedFeed === CONST.EXPENSIFY_CARD.NAME) { - const activeRoute = Navigation.getActiveRoute(); - Card.setIssueNewCardStepAndData({ step: CONST.EXPENSIFY_CARD.STEP.CARD_TYPE, data: { @@ -81,7 +79,7 @@ function WorkspaceMemberNewCardPage({route, personalDetails}: WorkspaceMemberNew }, isEditing: false, }); - Navigation.navigate(ROUTES.WORKSPACE_EXPENSIFY_CARD_ISSUE_NEW.getRoute(policyID, ROUTES.WORKSPACE_MEMBER_DETAILS.getRoute(policyID, accountID))); + Navigation.navigate(ROUTES.WORKSPACE_EXPENSIFY_CARD_ISSUE_NEW.getRoute(policyID, ROUTES.WORKSPACE_MEMBER_DETAILS.getRoute(policyID, accountID))); } else { CompanyCards.setAssignCardStepAndData({ currentStep: CONST.COMPANY_CARD.STEP.CARD,