sendFile with content

This commit is contained in:
abalabahaha
2016-04-13 10:50:03 -07:00
parent ecc35eecda
commit 9251fd01ce
2 changed files with 6 additions and 4 deletions

View File

@@ -747,7 +747,7 @@ var InternalClient = (function () {
// def sendFile
InternalClient.prototype.sendFile = function sendFile(where, _file, name) {
InternalClient.prototype.sendFile = function sendFile(where, _file, name, content) {
var _this19 = this;
if (!name) {
@@ -765,7 +765,8 @@ var InternalClient = (function () {
return _this19.resolver.resolveFile(_file).then(function (file) {
return _this19.apiRequest("post", _Constants.Endpoints.CHANNEL_MESSAGES(channel.id), true, null, {
name: name,
file: file
file: file,
content: content
}).then(function (res) {
return channel.messages.add(new _StructuresMessage2["default"](res, channel, _this19.client));
});