From b59bccc0706129977c4f599a57a8706b5d9cd7be Mon Sep 17 00:00:00 2001 From: George Hazan Date: Fri, 29 Dec 2023 17:38:01 +0300 Subject: =?UTF-8?q?fixes=20#4084=20(ICQ:=20=D1=80=D0=B5=D0=B0=D0=BB=D0=B8?= =?UTF-8?q?=D0=B7=D0=BE=D0=B2=D0=B0=D1=82=D1=8C=20=D0=BF=D0=BE=D0=BA=D0=B0?= =?UTF-8?q?=D0=B7=20=D0=B8=D0=BD=D1=84=D0=BE=D1=80=D0=BC=D0=B0=D1=86=D0=B8?= =?UTF-8?q?=D0=B8=20=D0=BE=D0=B1=20=D0=98=D0=B7=D0=B1=D1=80=D0=B0=D0=BD?= =?UTF-8?q?=D0=BD=D0=BE=D0=BC)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- protocols/ICQ-WIM/src/server.cpp | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/protocols/ICQ-WIM/src/server.cpp b/protocols/ICQ-WIM/src/server.cpp index b2d3f66b2e..fc16ed5278 100644 --- a/protocols/ICQ-WIM/src/server.cpp +++ b/protocols/ICQ-WIM/src/server.cpp @@ -403,8 +403,10 @@ MCONTACT CIcqProto::ParseBuddyInfo(const JSONNode &buddy, MCONTACT hContact, boo const JSONNode &profile = buddy["profile"]; if (profile) { Json2string(hContact, profile, "friendlyName", DB_KEY_ICQNICK, bIsPartial); - Json2string(hContact, profile, "firstName", "FirstName", bIsPartial); - Json2string(hContact, profile, "lastName", "LastName", bIsPartial); + if (hContact != m_hFavContact) { + Json2string(hContact, profile, "firstName", "FirstName", bIsPartial); + Json2string(hContact, profile, "lastName", "LastName", bIsPartial); + } Json2string(hContact, profile, "aboutMe", DB_KEY_ABOUT, bIsPartial); ptrW wszNick(getWStringA(hContact, "Nick")); @@ -724,8 +726,10 @@ void CIcqProto::OnGePresence(NETLIBHTTPREQUEST *pReply, AsyncHttpRequest *pReq) return; auto &data = root.data(); - for (auto &it : data["users"]) + for (auto &it : data["users"]) { + ParseBuddyInfo(it, pReq->hContact, true); ProcessOnline(it, pReq->hContact); + } } void CIcqProto::RetrievePresence(MCONTACT hContact) -- cgit v1.2.3