Skip to content

Commit

Permalink
fix user still can remove invalid member
Browse files Browse the repository at this point in the history
  • Loading branch information
DylanDylann committed Sep 22, 2023
1 parent 8e2edbf commit cb3ebed
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/pages/workspace/WorkspaceMembersPage.js
Original file line number Diff line number Diff line change
Expand Up @@ -314,7 +314,11 @@ function WorkspaceMembersPage(props) {
keyForList: accountID,
accountID: Number(accountID),
isSelected: _.contains(selectedEmployees, Number(accountID)),
isDisabled: accountID === props.session.accountID || details.login === props.policy.owner || policyMember.pendingAction === CONST.RED_BRICK_ROAD_PENDING_ACTION.DELETE,
isDisabled:
accountID === props.session.accountID ||
details.login === props.policy.owner ||
policyMember.pendingAction === CONST.RED_BRICK_ROAD_PENDING_ACTION.DELETE ||
!_.isEmpty(policyMember.errors),
text: props.formatPhoneNumber(details.displayName),
alternateText: props.formatPhoneNumber(details.login),
rightElement: isAdmin ? (
Expand Down

0 comments on commit cb3ebed

Please sign in to comment.