|
|
@ -1531,8 +1531,7 @@ define([
|
|
|
|
Store.leavePad = function (clientId, data, cb) {
|
|
|
|
Store.leavePad = function (clientId, data, cb) {
|
|
|
|
var channel = channels[data.channel];
|
|
|
|
var channel = channels[data.channel];
|
|
|
|
if (!channel || !channel.cpNf) { return void cb ({error: 'EINVAL'}); }
|
|
|
|
if (!channel || !channel.cpNf) { return void cb ({error: 'EINVAL'}); }
|
|
|
|
channel.cpNf.stop();
|
|
|
|
Store.dropChannel(data.channel);
|
|
|
|
delete channels[data.channel];
|
|
|
|
|
|
|
|
cb();
|
|
|
|
cb();
|
|
|
|
};
|
|
|
|
};
|
|
|
|
Store.sendPadMsg = function (clientId, data, cb) {
|
|
|
|
Store.sendPadMsg = function (clientId, data, cb) {
|
|
|
@ -1850,7 +1849,7 @@ define([
|
|
|
|
// Clients management
|
|
|
|
// Clients management
|
|
|
|
var driveEventClients = [];
|
|
|
|
var driveEventClients = [];
|
|
|
|
|
|
|
|
|
|
|
|
var dropChannel = function (chanId) {
|
|
|
|
var dropChannel = Store.dropChannel = function (chanId) {
|
|
|
|
try {
|
|
|
|
try {
|
|
|
|
store.messenger.leavePad(chanId);
|
|
|
|
store.messenger.leavePad(chanId);
|
|
|
|
} catch (e) { console.error(e); }
|
|
|
|
} catch (e) { console.error(e); }
|
|
|
|