diff options
author | Robert Pösel <robyer@seznam.cz> | 2015-02-17 16:17:08 +0000 |
---|---|---|
committer | Robert Pösel <robyer@seznam.cz> | 2015-02-17 16:17:08 +0000 |
commit | 1144c13b3ced478e35f5e56ba0564887eacf54f9 (patch) | |
tree | 216194453ad8bf2d88cf69253da42510c7f7dd0a /protocols/FacebookRM/src/json.cpp | |
parent | 0fabeec3192ad9d346b7dadfb35b38d2866f14c7 (diff) |
Facebook: Completely remove option to use https and always use it; version bump
git-svn-id: http://svn.miranda-ng.org/main/trunk@12165 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'protocols/FacebookRM/src/json.cpp')
-rw-r--r-- | protocols/FacebookRM/src/json.cpp | 10 |
1 files changed, 3 insertions, 7 deletions
diff --git a/protocols/FacebookRM/src/json.cpp b/protocols/FacebookRM/src/json.cpp index 5597baebff..cd954ed1af 100644 --- a/protocols/FacebookRM/src/json.cpp +++ b/protocols/FacebookRM/src/json.cpp @@ -316,13 +316,9 @@ void parseAttachments(FacebookProto *proto, std::string *message_text, JSONNODE std::string link = json_as_pstring(url); if (link.find("/ajax/mercury/attachments/photo/view/") != std::string::npos) - // fix photo url - link = utils::url::decode(utils::text::source_get_value(&link, 2, "?uri=", "&")); - else if (link.find("/") == 0) { - // make absolute url - bool useHttps = proto->getByte(FACEBOOK_KEY_FORCE_HTTPS, 1) > 0; - link = (useHttps ? HTTP_PROTO_SECURE : HTTP_PROTO_REGULAR) + std::string(FACEBOOK_SERVER_REGULAR) + link; - } + link = utils::url::decode(utils::text::source_get_value(&link, 2, "?uri=", "&")); // fix photo url + else if (link.find("/") == 0) + link = HTTP_PROTO_SECURE FACEBOOK_SERVER_REGULAR + link; // make absolute url if (!link.empty()) { std::string filename; |