Skip to content

Commit

Permalink
Merge pull request #35117 from Expensify/nikki-dont-persist-plaid-error
Browse files Browse the repository at this point in the history
Don't persist error after reconnecting with plaid
  • Loading branch information
dangrous authored Jan 29, 2024
2 parents 2700886 + 803bae6 commit c5ab78f
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions src/pages/ReimbursementAccount/ReimbursementAccountPage.js
Original file line number Diff line number Diff line change
Expand Up @@ -315,6 +315,11 @@ function ReimbursementAccountPage({reimbursementAccount, route, onfidoToken, pol

const currentStepRouteParam = getStepToOpenFromRouteParams(route);
if (currentStepRouteParam === currentStep) {
// If the user is connecting online with plaid, reset any bank account errors so we don't persist old data from a potential previous connection
if (currentStep === CONST.BANK_ACCOUNT.STEP.BANK_ACCOUNT && achData.subStep === CONST.BANK_ACCOUNT.SETUP_TYPE.PLAID) {
BankAccounts.hideBankAccountErrors();
}

// The route is showing the correct step, no need to update the route param or clear errors.
return;
}
Expand Down

0 comments on commit c5ab78f

Please sign in to comment.