From 3369f559a78237faf25626228d1e56052a0bd2a2 Mon Sep 17 00:00:00 2001 From: mgabdev <> Date: Fri, 14 Aug 2020 12:46:48 -0500 Subject: [PATCH] Updated GroupMembers feature to not show action button if isAdmin and is current user MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit • Updated: - GroupMembers feature to not show action button if isAdmin and is current user --- app/javascript/gabsocial/features/group_members.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/app/javascript/gabsocial/features/group_members.js b/app/javascript/gabsocial/features/group_members.js index b359e537..d8b6e480 100644 --- a/app/javascript/gabsocial/features/group_members.js +++ b/app/javascript/gabsocial/features/group_members.js @@ -3,6 +3,7 @@ import ImmutablePropTypes from 'react-immutable-proptypes' import debounce from 'lodash.debounce' import isObject from 'lodash.isobject' import { FormattedMessage } from 'react-intl' +import { me } from '../initial_state' import { fetchMembers, expandMembers, @@ -128,7 +129,7 @@ class GroupMembers extends ImmutablePureComponent { compact key={id} id={id} - actionIcon={!isAdmin ? undefined : 'ellipsis'} + actionIcon={(!isAdmin || id === me) ? undefined : 'ellipsis'} onActionClick={(data, event) => { return !isAdmin ? false : this.handleOpenGroupMemberOptions(event, id) }}