bigbluebutton-Github/bigbluebutton-html5/imports/ui/services/meeting-settings/index.js

12 lines
350 B
JavaScript
Raw Normal View History

import Auth from '/imports/ui/services/auth';
import Meetings from '/imports/api/meetings';
export default function getFromMeetingSettings(setting, defaultValue) {
const meeting = Meetings.findOne(
{ meetingId: Auth.meetingID },
{ fields: { metadataProp: 1 } },
);
return meeting?.metadataProp?.metadata?.[setting] ?? defaultValue;
}