Fixed unbanMember and added getBans

This commit is contained in:
abalabahaha
2015-11-11 22:46:24 -08:00
parent 3e37c5d91f
commit db7da87cb4
4 changed files with 87 additions and 5 deletions

View File

@@ -219,6 +219,23 @@ var Client = (function (_EventEmitter) {
});
};
// def getBans
Client.prototype.getBans = function getBans(where) {
var callback = arguments.length <= 1 || arguments[1] === undefined ? function (err, logs) {} : arguments[1];
var self = this;
return new Promise(function (resolve, reject) {
self.internal.getBans(where).then(function (bans) {
callback(null, bans);
resolve(bans);
})["catch"](function (e) {
callback(e);
reject(e);
});
});
};
// def sendFile
Client.prototype.sendFile = function sendFile(where, attachment) {