Skip to content

Commit

Permalink
Always show at least one empty room for group join
Browse files Browse the repository at this point in the history
Signed-off-by: Andreas Greimel <[email protected]>
  • Loading branch information
greimela committed Jul 13, 2022
1 parent 76e800e commit 3e98f55
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion client/src/components/RoomGrid.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ const RoomGrid = (props: Props) => {

const minimumRoomsToShow = group.groupJoin.minimumRoomsToShow || 1;
const [emptyRooms, filledRooms] = partition(rooms, (room) => participantsInMeeting(room.meetingId).length === 0);
return [...filledRooms, ...emptyRooms.slice(0, minimumRoomsToShow - filledRooms.length)];
return [...filledRooms, ...emptyRooms.slice(0, Math.max(minimumRoomsToShow - filledRooms.length, 1))];
}

function renderRoomCards() {
Expand Down

0 comments on commit 3e98f55

Please sign in to comment.