The communications platform that puts data protection first.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
Rocket.Chat/packages/rocketchat-livechat/server/methods/sendMessageLivechat.js

18 lines
344 B

Meteor.methods({
sendMessageLivechat: function(message) {
var guest;
check(message.rid, String);
check(message.token, String);
guest = Meteor.users.findOne(Meteor.userId(), {
fields: {
name: 1,
username: 1,
department: 1
}
});
return RocketChat.Livechat.sendMessage({ guest: guest, message: message });
}
});