Fix: layout not propagating

This commit is contained in:
Tainan Felipe 2024-04-01 11:20:10 -03:00
parent fe8eacb647
commit 7c110e6f76

View File

@ -286,32 +286,19 @@ export default withTracker(() => {
},
);
const currentMeeting = Meetings.findOne({ meetingId: Auth.meetingID },
{
fields: {
randomlySelectedUser: 1,
layout: 1,
},
});
const {
randomlySelectedUser,
} = currentMeeting;
const meetingLayoutObj = Meetings
.findOne({ meetingId: Auth.meetingID }) || {};
const { layout } = meetingLayoutObj;
const {
currentLayoutType: meetingLayout,
propagateLayout: pushLayoutMeeting,
cameraDockIsResizing: isMeetingLayoutResizing,
cameraDockPlacement: meetingLayoutCameraPosition,
presentationVideoRate: meetingLayoutVideoRate,
cameraDockAspectRatio: meetingLayoutVideoRate,
cameraWithFocus: meetingLayoutFocusedCamera,
} = layout;
const meetingLayout = LAYOUT_TYPE[layout.currentLayoutType];
const meetingLayoutUpdatedAt = new Date(layout.updatedAt).getTime();
const meetingPresentationIsOpen = !layout.presentationMinimized;