From 255f3c1a291adbc5156177da47bff1961a381c9f Mon Sep 17 00:00:00 2001 From: George Hazan Date: Mon, 16 Sep 2024 20:34:22 +0300 Subject: =?UTF-8?q?fixes=20#4658=20(=D0=98=D0=BC=D1=8F=20=D1=87=D0=B0?= =?UTF-8?q?=D1=82=D0=B0=20=D0=B2=20=D0=B7=D0=B0=D0=B3=D0=BE=D0=BB=D0=BE?= =?UTF-8?q?=D0=B2=D0=BA=D0=B5=20=D0=BE=D0=BA=D0=BD=D0=B0=20=D1=81=D0=BE?= =?UTF-8?q?=D0=BE=D0=B1=D1=89=D0=B5=D0=BD=D0=B8=D0=B9=20=D0=BD=D0=B8=D0=BA?= =?UTF-8?q?=D0=BE=D0=B3=D0=B4=D0=B0=20=D0=BD=D0=B5=20=D0=BC=D0=B5=D0=BD?= =?UTF-8?q?=D1=8F=D0=B5=D1=82=D1=81=D1=8F)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- protocols/Telegram/src/utils.cpp | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) (limited to 'protocols/Telegram/src') diff --git a/protocols/Telegram/src/utils.cpp b/protocols/Telegram/src/utils.cpp index 0a1337da68..22055f305a 100644 --- a/protocols/Telegram/src/utils.cpp +++ b/protocols/Telegram/src/utils.cpp @@ -599,8 +599,12 @@ CMStringA CTelegramProto::GetMessageText(TG_USER *pUser, const TD::message *pMsg break; case TD::messageChatChangeTitle::ID: - if (auto *pDoc = (TD::messageChatChangeTitle *)pBody) - setUString(pUser->hContact, "Nick", pDoc->title_.c_str()); + if (auto *pDoc = (TD::messageChatChangeTitle *)pBody) { + if (pUser->m_si) + Chat_ChangeSessionName(pUser->m_si, Utf2T(pDoc->title_.c_str())); + else + setUString(pUser->hContact, "Nick", pDoc->title_.c_str()); + } break; case TD::messagePhoto::ID: -- cgit v1.2.3