mirror of
https://github.com/mattermost/mattermost.git
synced 2025-02-25 18:55:24 -06:00
Fix inactive users showing up in team members modal (#6260)
This commit is contained in:
committed by
Christopher Speller
parent
224ddb35cf
commit
83bfd95f65
@@ -629,10 +629,7 @@ export function checkMfa(loginId, success, error) {
|
||||
export function updateActive(userId, active, success, error) {
|
||||
Client.updateActive(userId, active,
|
||||
(data) => {
|
||||
AppDispatcher.handleServerAction({
|
||||
type: ActionTypes.RECEIVED_PROFILE,
|
||||
profile: data
|
||||
});
|
||||
UserStore.saveProfile(data);
|
||||
|
||||
if (success) {
|
||||
success(data);
|
||||
|
||||
@@ -44,7 +44,7 @@ export default class MemberListTeam extends React.Component {
|
||||
this.state = {
|
||||
users: UserStore.getProfileListInTeam(),
|
||||
teamMembers: Object.assign([], TeamStore.getMembersInTeam()),
|
||||
total: stats.total_member_count,
|
||||
total: stats.active_member_count,
|
||||
loading: true
|
||||
};
|
||||
}
|
||||
@@ -83,7 +83,7 @@ export default class MemberListTeam extends React.Component {
|
||||
|
||||
onStatsChange() {
|
||||
const stats = TeamStore.getCurrentStats();
|
||||
this.setState({total: stats.total_member_count});
|
||||
this.setState({total: stats.active_member_count});
|
||||
}
|
||||
|
||||
nextPage(page) {
|
||||
@@ -141,7 +141,7 @@ export default class MemberListTeam extends React.Component {
|
||||
for (let i = 0; i < users.length; i++) {
|
||||
const user = users[i];
|
||||
|
||||
if (teamMembers[user.id]) {
|
||||
if (teamMembers[user.id] && user.delete_at === 0) {
|
||||
usersToDisplay.push(user);
|
||||
actionUserProps[user.id] = {
|
||||
teamMember: teamMembers[user.id]
|
||||
|
||||
Reference in New Issue
Block a user