diff options
author | George Hazan <ghazan@miranda.im> | 2018-12-21 18:21:46 +0300 |
---|---|---|
committer | George Hazan <ghazan@miranda.im> | 2018-12-21 18:21:46 +0300 |
commit | 713da4848166da0cae6e857a27b3580349e536ef (patch) | |
tree | bfe6eab65ce6463e2754ad0c7732fe0f3540ac70 | |
parent | 01e5902caa74b8712ae014aee917e3403024646c (diff) |
code cleaning
-rw-r--r-- | protocols/FacebookRM/src/communication.cpp | 4 | ||||
-rw-r--r-- | protocols/FacebookRM/src/messages.cpp | 2 |
2 files changed, 3 insertions, 3 deletions
diff --git a/protocols/FacebookRM/src/communication.cpp b/protocols/FacebookRM/src/communication.cpp index f9d5b1f5af..7f5a0737e4 100644 --- a/protocols/FacebookRM/src/communication.cpp +++ b/protocols/FacebookRM/src/communication.cpp @@ -496,7 +496,7 @@ bool facebook_client::login(const char *username, const char *password) std::string nh = utils::text::source_get_value(&resp.data, 3, "name=\"nh\"", "value=\"", "\""); HttpRequest *request = setupMachineRequest(fb_dtsg.c_str(), nh.c_str(), "Continue"); - request->Body << "&name_action_selected=save_device"; // Save device - or "dont_save" + request->Body << CHAR_PARAM("name_action_selected", "save_device"); // Save device - or "dont_save" resp = sendRequest(request); } @@ -545,7 +545,7 @@ bool facebook_client::login(const char *username, const char *password) nh = utils::text::source_get_value(&resp.data, 3, "name=\"nh\"", "value=\"", "\""); HttpRequest *request = setupMachineRequest(fb_dtsg.c_str(), nh.c_str(), "Continue"); - request->Body << "&name_action_selected=save_device"; // Save device - or "dont_save" + request->Body << CHAR_PARAM("name_action_selected", "save_device"); // Save device - or "dont_save" resp = sendRequest(request); } } diff --git a/protocols/FacebookRM/src/messages.cpp b/protocols/FacebookRM/src/messages.cpp index 895628386d..7d5afc6fdc 100644 --- a/protocols/FacebookRM/src/messages.cpp +++ b/protocols/FacebookRM/src/messages.cpp @@ -247,7 +247,7 @@ HttpRequest* facebook_client::sendMessageRequest( if (message_text.substr(0, 10) == "[[sticker:" && message_text.substr(message_text.length() - 2) == "]]") // TODO: For sending GIF images instead of "sticker_id=" there is "image_ids[0]=", otherwise it's same p->Body - << "body=" + << CHAR_PARAM("body", "") << CHAR_PARAM("sticker_id", message_text.substr(10, message_text.length() - 10 - 2).c_str()) << BOOL_PARAM("has_attachment", true); else |