From c1cb0445fbed21a72dba66ec9c3ed0bef012f7c6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?H=C3=A5var=20Aamb=C3=B8=20Fosstveit?= Date: Mon, 23 Mar 2020 23:06:08 +0100 Subject: [PATCH] Wrong state handling --- .../ParticipantList/ParticipantList.js | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/app/src/components/MeetingDrawer/ParticipantList/ParticipantList.js b/app/src/components/MeetingDrawer/ParticipantList/ParticipantList.js index 01dbf9d..dbf5491 100644 --- a/app/src/components/MeetingDrawer/ParticipantList/ParticipantList.js +++ b/app/src/components/MeetingDrawer/ParticipantList/ParticipantList.js @@ -143,7 +143,11 @@ class ParticipantList extends React.PureComponent })} onClick={() => roomClient.setSelectedPeer(peerId)} > - + ))} @@ -165,12 +169,9 @@ ParticipantList.propTypes = const mapStateToProps = (state) => { - const isModerator = - state.me.roles.includes(userRoles.MODERATOR) || - state.me.roles.includes(userRoles.ADMIN); - return { - isModerator, + isModerator : state.me.roles.includes(userRoles.MODERATOR) || + state.me.roles.includes(userRoles.ADMIN), passivePeers : passivePeersSelector(state), selectedPeerId : state.room.selectedPeerId, spotlightPeers : spotlightPeersSelector(state)