Skip to content

Commit

Permalink
fix button text
Browse files Browse the repository at this point in the history
  • Loading branch information
luacmartins committed Jul 26, 2021
1 parent 3d35169 commit 4b4fbd9
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 2 deletions.
1 change: 1 addition & 0 deletions src/CONST.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions src/libs/actions/BankAccounts.js
Original file line number Diff line number Diff line change
Expand Up @@ -554,6 +554,7 @@ function validateBankAccount(bankAccountID, validateCode) {
Growl.show('Bank Account successfully validated!', CONST.GROWL.SUCCESS, 3000);
Navigation.dismissModal();
Onyx.merge(ONYXKEYS.REIMBURSEMENT_ACCOUNT, {loading: false, error: ''});
Onyx.merge(ONYXKEYS.USER, {isUsingExpensifyCard: true});
return;
}

Expand Down
5 changes: 3 additions & 2 deletions src/pages/workspace/WorkspaceCardPage.js
Original file line number Diff line number Diff line change
Expand Up @@ -70,13 +70,14 @@ const WorkspaceCardPage = ({
isSmallScreenWidth,
reimbursementAccount,
}) => {
const isVerifying = lodashGet(reimbursementAccount, 'achData.state', '') === CONST.BANK_ACCOUNT.STATE.VERIFYING;
const achDataState = lodashGet(reimbursementAccount, 'achData.state', '');
let buttonText;
if (user.isFromPublicDomain) {
buttonText = translate('workspace.card.addEmail');
} else if (user.isUsingExpensifyCard) {
buttonText = translate('workspace.card.manageCards');
} else if (isVerifying) {
} else if (achDataState === CONST.BANK_ACCOUNT.STATE.VERIFYING
|| achDataState === CONST.BANK_ACCOUNT.STATE.PENDING) {
buttonText = translate('workspace.card.finishSetup');
} else {
buttonText = translate('workspace.card.getStarted');
Expand Down

0 comments on commit 4b4fbd9

Please sign in to comment.