From 21e46e6bc391e90b6c23fcebb2809b63a2d526c2 Mon Sep 17 00:00:00 2001 From: George Hazan Date: Wed, 30 Apr 2025 20:44:12 +0300 Subject: Teams: fix for loading history --- protocols/Teams/src/teams_history.cpp | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) (limited to 'protocols/Teams/src') diff --git a/protocols/Teams/src/teams_history.cpp b/protocols/Teams/src/teams_history.cpp index 864e8a9290..78221846cf 100644 --- a/protocols/Teams/src/teams_history.cpp +++ b/protocols/Teams/src/teams_history.cpp @@ -133,10 +133,8 @@ void CTeamsProto::OnGetServerHistory(MHttpResponse *response, AsyncHttpRequest * CMStringA szChatId = UrlToSkypeId(message["conversationLink"].as_mstring(), &iUserType); CMStringA szFrom = UrlToSkypeId(message["from"].as_mstring()); - MCONTACT hContact = FindContact(szChatId); - DB::EventInfo dbei(db_event_getById(m_szModuleName, szMessageId)); - dbei.hContact = hContact; + dbei.hContact = pRequest->hContact; dbei.szModule = m_szModuleName; dbei.szId = szMessageId; dbei.bSent = IsMe(szFrom); @@ -158,7 +156,7 @@ void CTeamsProto::OnGetServerHistory(MHttpResponse *response, AsyncHttpRequest * if (dbei) db_event_edit(dbei.getEvent(), &dbei, true); else - db_event_add(hContact, &dbei); + db_event_add(pRequest->hContact, &dbei); } } -- cgit v1.2.3