summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJellyBrick <shlee1503@naver.com>2018-07-27 18:14:23 +0900
committerJellyBrick <shlee1503@naver.com>2018-07-27 18:14:23 +0900
commit9966efd8a5e006f5ba548c34ae3072000a150193 (patch)
tree09b60bd98101b901be4fa003ff20cb635ad1e7ba
parent85104c6a24a28d5a5eca05de4a5e59dd0059232d (diff)
Fix build error
-rw-r--r--include/tgbot/Api.h2
-rw-r--r--src/Api.cpp2
2 files changed, 2 insertions, 2 deletions
diff --git a/include/tgbot/Api.h b/include/tgbot/Api.h
index b10a87a..e926732 100644
--- a/include/tgbot/Api.h
+++ b/include/tgbot/Api.h
@@ -347,7 +347,7 @@ public:
* @param disableNotification Optional. Sends the message silenty.
* @return On success, the sent message is returned.
*/
- Message::Ptr sendVoice(int64_t chatId, InputFile::Ptr voice, const std::string& caption = "", int duration = 0, int32_t replyToMessageId = 0,
+ Message::Ptr sendVoice(int64_t chatId, boost::variant<InputFile::Ptr, std::string> voice, const std::string& caption = "", int duration = 0, int32_t replyToMessageId = 0,
GenericReply::Ptr replyMarkup = std::make_shared<GenericReply>(), const std::string& parseMode = "", bool disableNotification = false) const;
/**
diff --git a/src/Api.cpp b/src/Api.cpp
index 0e82ab1..14f4ec1 100644
--- a/src/Api.cpp
+++ b/src/Api.cpp
@@ -816,7 +816,7 @@ Message::Ptr editMessageMedia(InputMedia::Ptr media, int64_t chatId, int32_t mes
if (replyMarkup) {
args.emplace_back("reply_markup", _tgTypeParser.parseGenericReply(replyMarkup));
}
- ptree p = sendRequest("editMessageCaption", args);
+ ptree p = sendRequest("editMessageMedia", args);
if (p.get_child_optional("message_id")) {
return _tgTypeParser.parseJsonAndGetMessage(p);
} else {