bigbluebutton-Github/bigbluebutton-html5/imports/api/whiteboard-multi-user/server/publishers.js
2019-03-08 16:00:16 +00:00

22 lines
679 B
JavaScript

import WhiteboardMultiUser from '/imports/api/whiteboard-multi-user/';
import { Meteor } from 'meteor/meteor';
import { check } from 'meteor/check';
import Logger from '/imports/startup/server/logger';
function whiteboardMultiUser(credentials) {
const { meetingId, requesterUserId, requesterToken } = credentials;
check(meetingId, String);
Logger.debug(`Publishing whiteboard-multi-user for ${meetingId} ${requesterUserId} ${requesterToken}`);
return WhiteboardMultiUser.find({ meetingId });
}
function publish(...args) {
const boundMultiUser = whiteboardMultiUser.bind(this);
return boundMultiUser(...args);
}
Meteor.publish('whiteboard-multi-user', publish);