diff options
author | MikalaiR <nikolay.romanovich@narod.ru> | 2015-04-20 19:40:35 +0000 |
---|---|---|
committer | MikalaiR <nikolay.romanovich@narod.ru> | 2015-04-20 19:40:35 +0000 |
commit | 0ab99d5195c16d19aecf0e6d6867cc0a6ddfd66d (patch) | |
tree | 3b40d7449034a6fbf8b1c1b9af99e880295a32a7 /protocols/SkypeWeb/src/requests/chatrooms.h | |
parent | 4cbbc64544a96d365e0e1862b122b9dec8faf601 (diff) |
SkypeWeb: Chat creating part 1.
git-svn-id: http://svn.miranda-ng.org/main/trunk@12986 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'protocols/SkypeWeb/src/requests/chatrooms.h')
-rw-r--r-- | protocols/SkypeWeb/src/requests/chatrooms.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/protocols/SkypeWeb/src/requests/chatrooms.h b/protocols/SkypeWeb/src/requests/chatrooms.h index d23e86832c..49a3ef9892 100644 --- a/protocols/SkypeWeb/src/requests/chatrooms.h +++ b/protocols/SkypeWeb/src/requests/chatrooms.h @@ -45,7 +45,7 @@ public: class CreateChatroomRequest : public HttpRequest
{
public:
- CreateChatroomRequest(const char *regToken, const LIST<char> &skypenames, const LIST<char> &roles, const char *server = SKYPE_ENDPOINTS_HOST) :
+ CreateChatroomRequest(const char *regToken, const LIST<char> &skypenames,const char *selfname, const char *server = SKYPE_ENDPOINTS_HOST) :
HttpRequest(REQUEST_POST, FORMAT, "%s/v1/threads", server)
{
//{"members":[{"id":"8:user3","role":"User"},{"id":"8:user2","role":"User"},{"id":"8:user1","role":"Admin"}]}
@@ -57,7 +57,7 @@ public: CMStringA data = "{\"members\":[";
for (int i = 0; i < skypenames.getCount(); i++)
- data.AppendFormat("{\"id\":\"8:%s\",\"role\":\"%s\"},", skypenames[i], roles[i]);
+ data.AppendFormat("{\"id\":\"8:%s\",\"role\":\"%s\"},", skypenames[i], !mir_strcmpi(skypenames[i], selfname) ? "Admin" : "User");
data.Truncate(data.GetLength() - 1);
data.Append("]}");
|