Skip to content

Commit

Permalink
Merge pull request #43406 from Expensify/rodrigo-fix-show-invoiceroom…
Browse files Browse the repository at this point in the history
…-option

Stop showing archived invoice room as an option in participants picker
  • Loading branch information
cristipaval authored Jun 11, 2024
2 parents 2282810 + 1750973 commit 4f2901f
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/libs/OptionsListUtils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1933,7 +1933,8 @@ function getOptions(
const isCurrentUserOwnedPolicyExpenseChatThatCouldShow =
reportOption.isPolicyExpenseChat && reportOption.ownerAccountID === currentUserAccountID && includeOwnedWorkspaceChats && !reportOption.isArchivedRoom;

const shouldShowInvoiceRoom = includeInvoiceRooms && ReportUtils.isInvoiceRoom(reportOption.item) && ReportUtils.isPolicyAdmin(reportOption.policyID ?? '', policies);
const shouldShowInvoiceRoom =
includeInvoiceRooms && ReportUtils.isInvoiceRoom(reportOption.item) && ReportUtils.isPolicyAdmin(reportOption.policyID ?? '', policies) && !reportOption.isArchivedRoom;

/**
Exclude the report option if it doesn't meet any of the following conditions:
Expand Down

0 comments on commit 4f2901f

Please sign in to comment.