Fix a missing callback in closeChannel

pull/1/head
yflory 2018-01-10 16:46:46 +01:00
parent d74c2a0395
commit cd7c5abc3e
1 changed files with 1 additions and 1 deletions

View File

@ -45,7 +45,7 @@ var getChannelMetadata = function (Env, channelId, cb) {
};
var closeChannel = function (env, channelName, cb) {
if (!env.channels[channelName]) { return; }
if (!env.channels[channelName]) { return void cb(); }
try {
env.channels[channelName].writeStream.close();
delete env.channels[channelName];