You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[Due for payment 2026-10-21] [$175] Wallet - Legacy combo Expensify Card appears as two rows with the same last four digits #101428
Sign in as an account holding a legacy combo Expensify Card (paired physical + virtual card).
Go to Settings > Wallet.
Expected Result
The combo card shows as a single row, as it did before the walletConnectionStatus beta was removed.
Actual Result
The physical and virtual halves of the combo card render as two separate rows with the same ending digits and the same information, which is confusing.
Root cause PaymentMethodList only collapses same-domain Expensify Cards into one row when shouldShowConnectionStatus is off:
Remove the walletConnectionStatus beta changed the assigned-cards list in WalletPage/index.tsx from shouldShowConnectionStatus={shouldShowWalletConnectionStatus} to always-on, so grouping is now permanently skipped on the Wallet page. Nothing else dedupes combo pairs there — getAssignedCardSortKey only sorts the physical card first.
Proposed fix
Restore single-row grouping for combo cards on the Wallet page while keeping connection status/sync details visible. Combo cards are deprecated (no new ones can be created), but legacy ones still exist and should display the way they did before.
The Wallet page's combo-card grouping branch is now permanently dead code.
PaymentMethodList.tsx:446 only merges a second same-domain Expensify Card into an existing row when !shouldShowConnectionStatus. Remove the walletConnectionStatus beta replaced shouldShowConnectionStatus={shouldShowWalletConnectionStatus} with a hardcoded shouldShowConnectionStatus on both lists in WalletPage/index.tsx:723-731. WalletPage is the only caller that passes shouldShowAssignedCards, so the guard is now always false and both halves of a combo card fall through to the row push at :478.
The two rows look identical because both halves share domainName (same description) and have no cardTitle override (both fall back to card.bank). The last four is only appended to the description when nameValuePairs.issuedBy is set, which legacy combo halves do not have — see :466-471.
The gate conflates two unrelated things. Connection status does not apply to Expensify Cards at all: shouldShowCardLastSync at :328 excludes Expensify cards, and getCardConnectionStatusDisplay returns only an active/inactive badge for them. So grouping never needed to be disabled for connection status to work.
What changes do you think we should make in order to solve the problem?
Two changes in PaymentMethodList.tsx:
Drop the !shouldShowConnectionStatus term from the merge condition at :446-447. This alone restores the pre-regression single row. The merge body only folds errors and recomputes brickRoadIndicator, so no status or sync detail is lost, and the isAdminIssuedVirtualCard check keeps genuinely separate admin-issued virtual cards on their own rows.
Match on card.domainName, not the rendered description. The condition compares item.description === card.domainName, but the description comes from getDescriptionForPolicyDomainCard, which returns the policy name for workspace-feed domains. That comparison silently fails there. Carry domainName on the pushed item (next to the existing isGroupedCardDomain field in PaymentMethodItem) and key the merge off that instead.
Ordering already works: getAssignedCardSortKey puts the physical card first, so it becomes the surviving row, and the detail page it navigates to already renders both halves via getDomainCards. No change needed there.
Add a regression test. There is no test file for PaymentMethodList anywhere in tests/, which is how this slipped through. A test asserting one row for a combo pair and two rows for a physical card plus an admin-issued virtual card would lock the behavior in.
What alternative solutions did you explore? (Optional)
Alternatives considered, and one discrepancy in the report
Reuse getDisplayableExpensifyCards. This helper already does the correct domain-keyed collapse with the same isAdminIssuedVirtualCard guard, and it is unit tested. It is why the home "Your Spend" section shows one row while Wallet shows two — its only caller is useYourSpendData.ts:423. I'd avoid swapping it in wholesale, though: it also filters expired, zero-limit, and pending-issue/activate cards, so it would change which cards appear in Wallet at all — a wider behavior change than this bug warrants. It is still the right reference for the merge key.
Dedupe on lastFourPAN. Rejected. Every combo fixture in the repo gives the two halves different last fours (CardUtilsTest.ts:2745-2782, WalletExpensifyCardPageTest.tsx:280), so matching on it would both miss real pairs and risk collapsing unrelated cards. CardUtils.ts also documents explicitly that the "one domain ⇒ one physical+virtual pair" invariant holds only for Expensify cards, so any collapse must stay gated on isExpensifyCard.
Revert the beta removal. Rejected — it would take the connection-status feature down with it. The two concerns are independent.
One discrepancy worth noting: the report says the two rows show "the same ending digits", but per the description logic above, combo cards don't render a last four at all. The visible duplication is the title and domain/policy name. This doesn't change the root cause or the fix, but whoever verifies should expect two rows reading the same card name and domain rather than two visible "••1234" strings.
Verification note: I did not reproduce this on a live account — it needs an account holding a legacy combo card, which can't be provisioned (no new combo cards can be created). The root cause is static and unambiguous: a permanently-false guard on the only code path that collapses the pair.
Related issues: I searched open App issues for combo-card, duplicate-wallet-row, and walletConnectionStatus matches and found none covering this.
💡 Suggested AI code review rule
This looks like a recurring, mechanically detectable pattern, so it may be worth a coding-standards rule so the AI reviewer catches the next one. Proposed for Expensify/App:
Rule:CONSISTENCY-18 — Resolve every branch on a flag you hardcode
Condition: When a PR removes a beta or feature flag and replaces its reads with a hardcoded value, flag it unless every other branch on that flag — including negated ones in other files — has been resolved and its now-unreachable code deleted or rewritten. Hardcoding the enabled value silently disables anything guarded by the negation.
Why: The flag becomes a compile-time constant, so branches on its negation turn into dead code that no test or type check flags. Here it silently removed combo-card grouping from Settings > Wallet.
Search pattern: when a PR deletes an entry from CONST.BETAS or drops a usePermissions()/isBetaEnabled() read, grep the repo for the flag and the prop or variable it fed — !<name>, <name> &&, <name> ? — and treat any surviving branch on the negation as dead.
The full rule file, with the ❌/✅ code inline in App's app-coding-standards format, would go in Expensify/App itself. If it's worth adding, a maintainer can open it there as a draft PR.
Next Steps for Contributor+ team: To accept:@MelvinBot implement [this](https://github.com/Expensify/App/issues/101428) to create a draft PR. To refine:@MelvinBot <your feedback> To reject: Explain why you are rejecting Melvin's proposal.
changed the title [-][$175] Wallet - Legacy combo Expensify Card appears as two rows with the same last four digits[/-][+][Due for payment 2026-10-21] [$175] Wallet - Legacy combo Expensify Card appears as two rows with the same last four digits[/+]on Oct 14, 2026
The solution for this issue has been 🚀 deployed to production 🚀 in version 9.5.8-5 and is now subject to a 7-day regression period 📆. Here is the list of pull requests that resolve this issue:
If no regressions arise, payment will be issued on 2026-10-21. 🎊
The following checklist (instructions) will need to be completed before the issue can be closed. Please copy/paste the Contributor+ Checklist from here into a new comment on this GH and complete it. If you have the K2 extension, you can simply click: [this button]. If no checklist is needed for this issue, you can click: [no checklist button]
[Contributor] The offending PR and associated issue have been commented on, pointing out the bug it caused and why, so the author and reviewers can learn from the mistake.
[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: N/A — cosmetic duplicate-row display bug, not a core-flow blocker.
[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
Precondition:
Sign in with an account that has a legacy combo Expensify Card (paired physical + virtual card, same domain). If unavailable, paste this into the browser console instead:
Activity
melvin-bot commentedon Sep 17, 2026
Triggered auto assignment to Contributor-plus team member for initial proposal review - @FitseTLT (
External)melvin-bot commentedon Sep 17, 2026
Unable to auto-create job on Upwork. The BZ team member should create it manually for this issue.
MelvinBot commentedon Sep 17, 2026
Proposal
What is the root cause of that problem?
The Wallet page's combo-card grouping branch is now permanently dead code.
PaymentMethodList.tsx:446only merges a second same-domain Expensify Card into an existing row when!shouldShowConnectionStatus. Remove the walletConnectionStatus beta replacedshouldShowConnectionStatus={shouldShowWalletConnectionStatus}with a hardcodedshouldShowConnectionStatuson both lists inWalletPage/index.tsx:723-731. WalletPage is the only caller that passesshouldShowAssignedCards, so the guard is now alwaysfalseand both halves of a combo card fall through to the row push at:478.The two rows look identical because both halves share
domainName(same description) and have nocardTitleoverride (both fall back tocard.bank). The last four is only appended to the description whennameValuePairs.issuedByis set, which legacy combo halves do not have — see:466-471.The gate conflates two unrelated things. Connection status does not apply to Expensify Cards at all:
shouldShowCardLastSyncat:328excludes Expensify cards, andgetCardConnectionStatusDisplayreturns only an active/inactive badge for them. So grouping never needed to be disabled for connection status to work.What changes do you think we should make in order to solve the problem?
Two changes in
PaymentMethodList.tsx:Drop the
!shouldShowConnectionStatusterm from the merge condition at:446-447. This alone restores the pre-regression single row. The merge body only foldserrorsand recomputesbrickRoadIndicator, so no status or sync detail is lost, and theisAdminIssuedVirtualCardcheck keeps genuinely separate admin-issued virtual cards on their own rows.Match on
card.domainName, not the rendered description. The condition comparesitem.description === card.domainName, but the description comes fromgetDescriptionForPolicyDomainCard, which returns the policy name for workspace-feed domains. That comparison silently fails there. CarrydomainNameon the pushed item (next to the existingisGroupedCardDomainfield inPaymentMethodItem) and key the merge off that instead.Ordering already works:
getAssignedCardSortKeyputs the physical card first, so it becomes the surviving row, and the detail page it navigates to already renders both halves viagetDomainCards. No change needed there.Add a regression test. There is no test file for
PaymentMethodListanywhere intests/, which is how this slipped through. A test asserting one row for a combo pair and two rows for a physical card plus an admin-issued virtual card would lock the behavior in.What alternative solutions did you explore? (Optional)
Alternatives considered, and one discrepancy in the report
Reuse
getDisplayableExpensifyCards. This helper already does the correct domain-keyed collapse with the sameisAdminIssuedVirtualCardguard, and it is unit tested. It is why the home "Your Spend" section shows one row while Wallet shows two — its only caller isuseYourSpendData.ts:423. I'd avoid swapping it in wholesale, though: it also filters expired, zero-limit, and pending-issue/activate cards, so it would change which cards appear in Wallet at all — a wider behavior change than this bug warrants. It is still the right reference for the merge key.Dedupe on
lastFourPAN. Rejected. Every combo fixture in the repo gives the two halves different last fours (CardUtilsTest.ts:2745-2782,WalletExpensifyCardPageTest.tsx:280), so matching on it would both miss real pairs and risk collapsing unrelated cards.CardUtils.tsalso documents explicitly that the "one domain ⇒ one physical+virtual pair" invariant holds only for Expensify cards, so any collapse must stay gated onisExpensifyCard.Revert the beta removal. Rejected — it would take the connection-status feature down with it. The two concerns are independent.
One discrepancy worth noting: the report says the two rows show "the same ending digits", but per the description logic above, combo cards don't render a last four at all. The visible duplication is the title and domain/policy name. This doesn't change the root cause or the fix, but whoever verifies should expect two rows reading the same card name and domain rather than two visible "••1234" strings.
Verification note: I did not reproduce this on a live account — it needs an account holding a legacy combo card, which can't be provisioned (no new combo cards can be created). The root cause is static and unambiguous: a permanently-false guard on the only code path that collapses the pair.
Related issues: I searched open App issues for combo-card, duplicate-wallet-row, and
walletConnectionStatusmatches and found none covering this.💡 Suggested AI code review rule
This looks like a recurring, mechanically detectable pattern, so it may be worth a coding-standards rule so the AI reviewer catches the next one. Proposed for
Expensify/App:CONSISTENCY-18— Resolve every branch on a flag you hardcodeCONST.BETASor drops ausePermissions()/isBetaEnabled()read, grep the repo for the flag and the prop or variable it fed —!<name>,<name> &&,<name> ?— and treat any surviving branch on the negation as dead.WalletPage/index.tsx:723-731hardcodes the prop; the branch it killed isPaymentMethodList.tsx:446.The full rule file, with the ❌/✅ code inline in App's
app-coding-standardsformat, would go inExpensify/Appitself. If it's worth adding, a maintainer can open it there as a draft PR.Next Steps for Contributor+ team:
To accept:
@MelvinBot implement [this](https://github.com/Expensify/App/issues/101428)to create a draft PR.To refine:
@MelvinBot <your feedback>To reject: Explain why you are rejecting Melvin's proposal.
view run
FitseTLT commentedon Sep 22, 2026
Will review tomorrow
melvin-bot commentedon Sep 25, 2026
@FitseTLT Uh oh! This issue is overdue by 2 days. Don't forget to update your issues!
FitseTLT commentedon Sep 25, 2026
Will review on Monday
melvin-bot commentedon Sep 29, 2026
@FitseTLT Uh oh! This issue is overdue by 2 days. Don't forget to update your issues!
26 remaining items
[-][$175] Wallet - Legacy combo Expensify Card appears as two rows with the same last four digits[/-][+][Due for payment 2026-10-21] [$175] Wallet - Legacy combo Expensify Card appears as two rows with the same last four digits[/+]melvin-bot commentedon Oct 14, 2026
@FitseTLT
The solution for this issue has been 🚀 deployed to production 🚀 in version 9.5.8-5 and is now subject to a 7-day regression period 📆. Here is the list of pull requests that resolve this issue:
If no regressions arise, payment will be issued on 2026-10-21. 🎊
The following checklist (instructions) will need to be completed before the issue can be closed. Please copy/paste the Contributor+ Checklist from here into a new comment on this GH and complete it. If you have the K2 extension, you can simply click: [this button]. If no checklist is needed for this issue, you can click: [no checklist button]
FitseTLT commentedon Oct 14, 2026
Contributor+ Checklist:
[Contributor] The offending PR and associated issue have been commented on, pointing out the bug it caused and why, so the author and reviewers can learn from the mistake.
Link to the comment on the PR: https://github.com/Expensify/App/pull/99754/changes#r4271210965
Link to the comment on the Issue:
[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: N/A — cosmetic duplicate-row display bug, not a core-flow blocker.
[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
Precondition:
Combo card mock (paste into the JS console)
Test:
My physical card, not two rows with the same1234ending.Do we agree 👍 or 👎
melvin-bot commentedon Oct 20, 2026
Triggered auto assignment to @mallenexpensify (
Awaiting Payment)melvin-bot commentedon Oct 20, 2026
Payment Summary
Resolving PRs:
Show legacy combo Expensify Cards as one row in Wallet #103199
Reviewer: @FitseTLT owed $175 via NewDot
BugZero Checklist (@mallenexpensify)
mallenexpensify commentedon Oct 21, 2026
Payment Summary
Contributor+: @FitseTLT due $250 via NewDot
Assigned before 2026-09-19
flaviadefaria commentedon Oct 23, 2026
Approved: @FitseTLT due $250 via NewDot