diff --git a/src/telegram.js b/src/telegram.js index ee653b8..ce4e937 100644 --- a/src/telegram.js +++ b/src/telegram.js @@ -7,6 +7,7 @@ var EventEmitter = require('events').EventEmitter; var fileType = require('file-type'); var Promise = require('bluebird'); var request = require('request'); +var qs = require('querystring'); var stream = require('stream'); var util = require('util'); var mime = require('mime'); @@ -277,7 +278,7 @@ TelegramBot.prototype._formatSendData = function (type, data) { formData[type] = { value: data, options: { - filename: fileName, + filename: qs.unescape(fileName), contentType: mime.lookup(fileName) } };