summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGeorge Hazan <george.hazan@gmail.com>2024-10-18 13:13:25 +0300
committerGeorge Hazan <george.hazan@gmail.com>2024-10-18 13:13:25 +0300
commit9f3e29551b636902d5a224c6ef4cc8aba6526810 (patch)
treea522d28986a5daa015b94b72a4c6af9becac1239
parent1e96a844ce8ebd7d2a9afd9d340db92c5b19b130 (diff)
Telegram: if user removed his nick, then don't store it anymore
-rw-r--r--protocols/Telegram/src/server.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/protocols/Telegram/src/server.cpp b/protocols/Telegram/src/server.cpp
index 681a4344be..1f5c204abe 100644
--- a/protocols/Telegram/src/server.cpp
+++ b/protocols/Telegram/src/server.cpp
@@ -1225,6 +1225,8 @@ void CTelegramProto::ProcessUser(TD::updateUser *pObj)
if (pUser->usernames_)
UpdateString(pu->hContact, "Nick", pUser->usernames_->editable_username_);
+ else
+ delSetting(pu->hContact, "Nick");
Contact::PutOnList(pu->hContact);