bigbluebutton-Github/bigbluebutton-html5/imports/api/annotations/server/methods/sendAnnotations.js
2022-05-13 02:47:39 +00:00

18 lines
603 B
JavaScript
Executable File

import { check } from 'meteor/check';
import sendAnnotationHelper from './sendAnnotationHelper';
import { extractCredentials } from '/imports/api/common/server/helpers';
import Logger from '/imports/startup/server/logger';
export default function sendAnnotations(annotations) {
try {
const { meetingId, requesterUserId } = extractCredentials(this.userId);
check(meetingId, String);
check(requesterUserId, String);
sendAnnotationHelper(annotations, meetingId, requesterUserId);
} catch (err) {
Logger.error(`Exception while invoking method sendAnnotation ${err.stack}`);
}
}