diff --git a/lib/commands/channel.js b/lib/commands/channel.js index c3d354881..72b9d6bcd 100644 --- a/lib/commands/channel.js +++ b/lib/commands/channel.js @@ -254,7 +254,8 @@ var ARRAY_LINE = /^\[/; call back with true if the channel log has no content other than metadata otherwise false */ -Channel.isNewChannel = function (Env, channel, cb) { +Channel.isNewChannel = function (Env, channel, _cb) { + var cb = Util.once(_cb); if (!Core.isValidId(channel)) { return void cb('INVALID_CHAN'); } if (channel.length !== HK.STANDARD_CHANNEL_LENGTH && channel.length !== HK.ADMIN_CHANNEL_LENGTH) { return void cb('INVALID_CHAN'); }