From e1b3b9a9235a7d9bd584a328322be9e2c92d177e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Robert=20P=C3=B6sel?= Date: Mon, 10 Sep 2012 00:21:32 +0000 Subject: Facebook: Fixed updating contact's avatars git-svn-id: http://svn.miranda-ng.org/main/trunk@1556 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c --- protocols/FacebookRM/avatars.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'protocols/FacebookRM/avatars.cpp') diff --git a/protocols/FacebookRM/avatars.cpp b/protocols/FacebookRM/avatars.cpp index 0ebfa7a558..2239843ef6 100644 --- a/protocols/FacebookRM/avatars.cpp +++ b/protocols/FacebookRM/avatars.cpp @@ -71,7 +71,7 @@ void FacebookProto::CheckAvatarChange(HANDLE hContact, std::string image_url) DBVARIANT dbv; bool update_required = true; - if (!DBGetContactSettingTString(hContact, m_szModuleName, FACEBOOK_KEY_AV_URL, &dbv)) + if (!DBGetContactSettingString(hContact, m_szModuleName, FACEBOOK_KEY_AV_URL, &dbv)) { update_required = image_url != dbv.pszVal; DBFreeVariant(&dbv); @@ -80,7 +80,10 @@ void FacebookProto::CheckAvatarChange(HANDLE hContact, std::string image_url) { DBWriteContactSettingString(hContact, m_szModuleName, FACEBOOK_KEY_AV_URL, image_url.c_str()); if (hContact) + { + DBWriteContactSettingByte(hContact, "ContactPhoto", "NeedUpdate", 1); ProtoBroadcastAck(m_szModuleName, hContact, ACKTYPE_AVATAR, ACKRESULT_STATUS, NULL, 0); + } else { PROTO_AVATAR_INFORMATIONT ai = {sizeof(ai)}; -- cgit v1.2.3