diff options
author | George Hazan <george.hazan@gmail.com> | 2024-01-24 16:16:01 +0300 |
---|---|---|
committer | George Hazan <george.hazan@gmail.com> | 2024-01-24 16:16:01 +0300 |
commit | 06e159dd5fdcf09d98ca013ce7a1231bf0751205 (patch) | |
tree | 8202a379c6a5a1f1f490b8af1acd16192ba6132f /protocols | |
parent | cf30319150edb0d5b49b05078817725c629320ba (diff) |
Telegram: activating flags for deleting contact
Diffstat (limited to 'protocols')
-rw-r--r-- | protocols/Telegram/src/proto.cpp | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/protocols/Telegram/src/proto.cpp b/protocols/Telegram/src/proto.cpp index 9b9b9bb4f5..3b79b01e66 100644 --- a/protocols/Telegram/src/proto.cpp +++ b/protocols/Telegram/src/proto.cpp @@ -117,13 +117,16 @@ void CTelegramProto::OnContactAdded(MCONTACT hContact) } } -bool CTelegramProto::OnContactDeleted(MCONTACT hContact, uint32_t) +bool CTelegramProto::OnContactDeleted(MCONTACT hContact, uint32_t flags) { TD::int53 id = GetId(hContact); if (id == 0) return false; if (auto *pUser = FindUser(id)) { + if (flags & CDF_DEL_HISTORY) + SvcEmptyServerHistory(hContact, flags); + if (pUser->m_si) { SvcLeaveChat(hContact, 0); return false; |