summaryrefslogtreecommitdiff
path: root/src/Api.cpp
diff options
context:
space:
mode:
authorOleg Morozenkov <m@oleg.rocks>2019-12-05 01:06:02 +0300
committerOleg Morozenkov <m@oleg.rocks>2019-12-05 01:06:02 +0300
commit2b5baa24597778d8e9f5d93c30a6f6440ef90971 (patch)
tree589202ffbaecb0ff2176575688e30cf18b317a61 /src/Api.cpp
parente1031f20f9139a554c3e4cf70585ae0dcea1bcda (diff)
parent76f36598570a13862471175cbfdbfb9dec4139d2 (diff)
Merge branch 'master' into nitanmarcel/api_update_pr
Diffstat (limited to 'src/Api.cpp')
-rw-r--r--src/Api.cpp7
1 files changed, 3 insertions, 4 deletions
diff --git a/src/Api.cpp b/src/Api.cpp
index ee8f36f..19681f7 100644
--- a/src/Api.cpp
+++ b/src/Api.cpp
@@ -336,12 +336,11 @@ bool Api::createNewStickerSet(int32_t userId, const string& name, const string&
return sendRequest("createNewStickerSet", args).get<bool>("", false);
}
-bool Api::addStickerToSet(int32_t userId, const string& name, const string& title, const boost::variant<InputFile::Ptr, std::string> pngSticker, const string& emojis, MaskPosition::Ptr maskPosition) const {
+bool Api::addStickerToSet(int32_t userId, const string& name, const boost::variant<InputFile::Ptr, std::string> pngSticker, const string& emojis, MaskPosition::Ptr maskPosition) const {
vector<HttpReqArg> args;
args.reserve(6);
args.emplace_back("user_id", userId);
args.emplace_back("name", name);
- args.emplace_back("title", title);
if (pngSticker.which() == 0 /* InputFile::Ptr */) {
auto file = boost::get<InputFile::Ptr>(pngSticker);
args.emplace_back("png_sticker", file->data, true, file->mimeType, file->fileName);
@@ -363,11 +362,11 @@ bool Api::setStickerPositionInSet(const string& sticker, uint32_t position) cons
return sendRequest("setStickerPositionInSet", args).get<bool>("", false);
}
-bool Api::deleteStickerPositionInSet(const string& sticker) const {
+bool Api::deleteStickerFromSet(const string& sticker) const {
vector<HttpReqArg> args;
args.reserve(1);
args.emplace_back("sticker", sticker);
- return sendRequest("setStickerPositionInSet", args).get<bool>("", false);
+ return sendRequest("deleteStickerFromSet", args).get<bool>("", false);
}
Message::Ptr Api::sendVideo(int64_t chatId, const boost::variant<InputFile::Ptr, std::string> video, bool supportsStreaming, int32_t duration, int32_t width, int32_t height, const boost::variant<InputFile::Ptr, std::string> thumb, const string &caption, int32_t replyToMessageId, const GenericReply::Ptr replyMarkup, const string& parseMode, bool disableNotification) const {