bigbluebutton-Github/bigbluebutton-html5/imports/api/guest-users/server/handlers/guestApproved.js
2019-04-05 13:52:13 +00:00

12 lines
387 B
JavaScript

import { check } from 'meteor/check';
import setGuestStatus from '../modifiers/setGuestStatus';
export default function handleGuestApproved({ body }, meetingId) {
const { approvedBy, guests } = body;
check(meetingId, String);
check(approvedBy, String);
check(guests, Array);
return guests.forEach(guest => setGuestStatus(meetingId, guest.guest, guest.status, approvedBy));
}