From 98005e927fb727f1590307caad8bfa106c07350d Mon Sep 17 00:00:00 2001 From: Aldo Canepa Date: Tue, 20 Jun 2023 12:00:51 -0700 Subject: [PATCH] personalDetails.login can be missing for new accounts --- src/pages/workspace/WorkspaceMembersPage.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/pages/workspace/WorkspaceMembersPage.js b/src/pages/workspace/WorkspaceMembersPage.js index 509bc439c0e2..4c170deb9ec5 100644 --- a/src/pages/workspace/WorkspaceMembersPage.js +++ b/src/pages/workspace/WorkspaceMembersPage.js @@ -379,7 +379,7 @@ function WorkspaceMembersPage(props) { // We don't want to show guides as policy members unless the user is a guide. Some customers get confused when they // see random people added to their policy, but guides having access to the policies help set them up. if (policyOwner && currentUserLogin && !PolicyUtils.isExpensifyTeam(policyOwner) && !PolicyUtils.isExpensifyTeam(currentUserLogin)) { - data = _.reject(data, (member) => PolicyUtils.isExpensifyTeam(member.login)); + data = _.reject(data, (member) => PolicyUtils.isExpensifyTeam(member.login || member.displayName)); } _.each(data, (member) => {