Skip to content

[Due for payment 2026-06-19] [$250] Invoice - Impossible to add second bank account #76723

Closed

Description

@nlemma

If you haven’t already, check out our contributing guidelines for onboarding and email contributors@expensify.com to request to join our Slack channel!


Version Number: 9.2.71-5
Reproducible in staging?: Yes
Reproducible in production?: Yes
If this was caught during regression testing, add the test name, ID and link from BrowserStack: https://github.com/Expensify/Expensify/issues/465131
Email or phone of affected tester (no customers): N/A
Issue reported by: Applause Internal Team
Device used: macOS Monterey 12.7.4
App Component: Other

Action Performed:

Precondition: user with workspace with enabled Invoices feature.

Steps:

  1. Go to the Invoices page of a workspace.
  2. Click Add Bank Account and follow the steps to add an account.
  3. Add a second bank account.

Expected Result:

After step 2: the newly added bank account is not marked as the default, and the "Make default payment method" option is not visible.
There is an option to add bank account.

Actual Result:

After step 2: the newly added bank account is not marked as the default, and the "Make default payment method" option is visible.
There is no option Add bank account (for second one) if bank account already added.

Workaround:

Unknown

Platforms:

  • Android: App
  • Android: mWeb Chrome
  • iOS: App
  • iOS: mWeb Safari
  • iOS: mWeb Chrome
  • Windows: Chrome
  • MacOS: Chrome / Safari
  • MacOS: Desktop

Screenshots/Videos

Bug7011477_1763905944549.Screen_Recording_2025-11-23_at_15.46.11.mp4

View all open jobs on GitHub

Upwork Automation - Do Not Edit
  • Upwork Job URL: https://www.upwork.com/jobs/~021997856818617002003
  • Upwork Job ID: 1997856818617002003
  • Last Price Increase: 2026-05-19
Issue OwnerCurrent Issue Owner: @Ollyws

Activity

  1. added
    BugSomething is broken. Auto assigns a BugZero manager.
    on Dec 4, 2025
  2. melvin-bot commented on Dec 4, 2025

    @melvin-bot

    Triggered auto assignment to @VictoriaExpensify (Bug), see https://stackoverflow.com/c/expensify/questions/14418 for more details. Please add this bug to a GH project, as outlined in the SO.

  3. added
    ExternalAdded to denote the issue can be worked on by a contributor
    on Dec 8, 2025
  4. changed the title [-]Invoice - Impossible to add second bank account[/-] [+][$250] Invoice - Impossible to add second bank account[/+] on Dec 8, 2025
  5. melvin-bot commented on Dec 8, 2025

    @melvin-bot
  6. added
    Help WantedApply this label when an issue is open to proposals by contributors
    on Dec 8, 2025
  7. melvin-bot commented on Dec 8, 2025

    @melvin-bot

    Triggered auto assignment to Contributor-plus team member for initial proposal review - @Ollyws (External)

  8. melvin-bot commented on Dec 12, 2025

    @melvin-bot

    @Ollyws Whoops! This issue is 2 days overdue. Let's get this updated quick!

  9. 103 remaining items

  10. mallenexpensify commented on Jun 22, 2026

    @mallenexpensify
    Contributor

    @Ollyws plz complete the BZ checklist and tag me in a post once you have. Thx

    @nabi-ebrahimi in a dedicated post, can you enter your Upwork details? I'm hoping they'll be saved to send you auto-offers in the future. Thx

    Contributor details
    Your Expensify account email: email@email.com
    Upwork Profile Link: upwork.com/freelancers/~xxxxx

  11. nabi-ebrahimi commented on Jun 23, 2026

    @nabi-ebrahimi
    Contributor

    @mallenexpensify, i tried again here #94150 (comment), thanks.

    Image
  12. mallenexpensify commented on Jun 23, 2026

    @mallenexpensify
    Contributor

    Thanks @nabi-ebrahimi
    @Ollyws plz complete the BZ checklist and tag me in a post once you have. Thx

  13. Ollyws commented on Jun 24, 2026

    @Ollyws
    Contributor

    @MelvinBot which PR is responsible for this bug?

  14. MelvinBot commented on Jun 24, 2026

    @MelvinBot
    Contributor

    The bug was introduced by #47218 — "Invoicing bank accounts section" (merged 2024-09-30, commit d273a5ae8).

    That PR added the invoice default-bank-account feature and, in doing so, set the menu condition to the overly-broad:

    const shouldShowMakeDefaultButton = !paymentMethod.isSelectedPaymentMethodDefault;

    With only one invoice bank account, transferBankAccountID is empty, so isSelectedPaymentMethodDefault is false and "Make default payment method" is shown when it shouldn't be — exactly the reported symptom. This is the same line the approved fix #91167 replaced with a multi-eligible-account guard.

    Evidence

    The shouldShowMakeDefaultButton line was first written in its buggy form in #47218's diff for src/pages/workspace/invoices/WorkspaceInvoiceVBASection.tsx:

    -    const shouldShowMakeDefaultButton =
    -        !paymentMethod.isSelectedPaymentMethodDefault &&
    -        !(paymentMethod.formattedSelectedPaymentMethod.type === CONST.PAYMENT_METHODS.PERSONAL_BANK_ACCOUNT && paymentMethod.selectedPaymentMethod.type === CONST.BANK_ACCOUNT.TYPE.BUSINESS);
    +    const shouldShowMakeDefaultButton = !paymentMethod.isSelectedPaymentMethodDefault;

    Fix #91167 changed that same line to:

    const shouldShowMakeDefaultButton = !paymentMethod.isSelectedPaymentMethodDefault && (hasMultipleEligibleBankAccounts || isInvoiceDefaultBankAccountMissing);
  15. Ollyws commented on Jun 24, 2026

    @Ollyws
    Contributor

    BugZero Checklist:

    • [Contributor] Classify the bug:
    Bug classification

    Source of bug:

    • 1a. Result of the original design (eg. a case wasn't considered)
    • 1b. Mistake during implementation
    • 1c. Backend bug
    • 1z. Other:

    Where bug was reported:

    • 2a. Reported on production
    • 2b. Reported on staging (deploy blocker)
    • 2c. Reported on both staging and production
    • 2d. Reported on a PR
    • 2z. Other:

    Who reported the bug:

    • 3a. Expensify user
    • 3b. Expensify employee
    • 3c. Contributor
    • 3d. QA
    • 3z. Other:
    • [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: https://github.com/Expensify/App/pull/47218/changes#r3469170157

    • [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:

    • [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.

    Regression Test Proposal Template

    Regression Test Proposal

    Precondition:

    Test:

    Issue 1: One invoice bank account shows Make default payment method.

    1. Go to a workspace Invoices page.
    2. Add one bank account.
    3. Open the three-dot menu for that bank account.
    4. Verify that
    
        The bank account is not marked as default.
        The Make default payment method is not shown when there is only one eligible invoice bank account.
        The Add bank account should remain available so the user can add another account.
    

    Issue 2: Two invoice bank accounts should only show Make default payment method for the non-default account

    1. Go to a workspace Invoices page.
    2. Add a first bank account.
    3. Add a second bank account.
    4. Open the three-dot menu for each bank account.
    5. Verify that
    
        The invoice default bank account should show the 'Default' badge.
        The Make default payment method should be hidden for the default bank account.
        The Make default payment method should be shown only for the non-default bank account.
    

    Do we agree 👍 or 👎

    Zapier Logs Run ID: 00040eee-54c5-a03e-8fb8-d8484375ee94
  16. Ollyws commented on Jun 24, 2026

    @Ollyws
    Contributor

    @mallenexpensify all done and payment requested.

  17. flaviadefaria commented on Jun 30, 2026

    @flaviadefaria
    Contributor

    Approved: @Ollyws due $250 via NewDot

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Labels

Awaiting PaymentAuto-added when associated PR is deployed to productionBugSomething is broken. Auto assigns a BugZero manager.DailyKSv2ExternalAdded to denote the issue can be worked on by a contributor

Type

No type

Projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions