Added deleteChannel implementation

This commit is contained in:
hydrabolt
2015-11-02 17:21:27 +00:00
parent 25f0408fae
commit ff9c9b5647
4 changed files with 82 additions and 1 deletions

View File

@@ -261,6 +261,23 @@ class Client extends EventEmitter {
});
}
// def deleteChannel
deleteChannel(channel, callback=function(err){}){
var self = this;
return new Promise((resolve, reject) => {
self.internal.deleteChannel(channel)
.then( () => {
callback();
resolve();
})
.catch( e => {
callback(e); reject(e);
})
});
}
}
module.exports = Client;