Merge pull request #8573 from Tainan404/issue-8569
Show right breakout room in free join mode
This commit is contained in:
commit
96e13140e3
@ -76,10 +76,11 @@ class BreakoutRoomInvitation extends Component {
|
||||
if (hasBreakouts && !breakoutUserIsIn && !amIModerator) {
|
||||
// Have to check for freeJoin breakouts first because currentBreakoutUser will
|
||||
// populate after a room has been joined
|
||||
const breakoutRoom = getBreakoutByUser(currentBreakoutUser);
|
||||
const freeJoinBreakout = breakouts.find(breakout => breakout.freeJoin);
|
||||
if (freeJoinBreakout) {
|
||||
if (!didSendBreakoutInvite) {
|
||||
this.inviteUserToBreakout(freeJoinBreakout);
|
||||
this.inviteUserToBreakout(breakoutRoom || freeJoinBreakout);
|
||||
this.setState({ didSendBreakoutInvite: true });
|
||||
}
|
||||
} else if (currentBreakoutUser) {
|
||||
@ -87,7 +88,6 @@ class BreakoutRoomInvitation extends Component {
|
||||
const oldCurrentUser = oldProps.currentBreakoutUser || {};
|
||||
const oldInsertedTime = oldCurrentUser.insertedTime;
|
||||
if (currentInsertedTime !== oldInsertedTime) {
|
||||
const breakoutRoom = getBreakoutByUser(currentBreakoutUser);
|
||||
const breakoutId = Session.get('lastBreakoutOpened');
|
||||
if (breakoutRoom.breakoutId !== breakoutId) {
|
||||
this.inviteUserToBreakout(breakoutRoom);
|
||||
|
Loading…
Reference in New Issue
Block a user