bigbluebutton-Github/bigbluebutton-html5/imports/ui/services/features/index.js

18 lines
575 B
JavaScript
Raw Normal View History

2022-02-07 21:22:52 +08:00
import Auth from '/imports/ui/services/auth';
import Meetings from '/imports/api/meetings';
export function getDisabledFeatures() {
const selector = {
meetingId: Auth.meetingID,
};
const meetingData = Meetings.findOne(selector, { fields: { 'meetingProp.disabledFeatures': 1 } });
const disabledFeatures = ((meetingData || {}).meetingProp || {}).disabledFeatures || [];
2022-02-07 21:22:52 +08:00
return disabledFeatures;
}
export function isScreenSharingEnabled() {
return getDisabledFeatures().indexOf('screenshare') === -1 && Meteor.settings.public.kurento.enableScreensharing;
2022-02-07 21:22:52 +08:00
}