From 4249a8bf41513f14bdeead32c6cbc00389f9db74 Mon Sep 17 00:00:00 2001 From: Bohdan Horbeshko Date: Mon, 18 Sep 2023 00:02:49 -0400 Subject: Suppress nickname presences for MUCs better --- telegram/handlers.go | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'telegram/handlers.go') diff --git a/telegram/handlers.go b/telegram/handlers.go index 0d1cda9..71b55bc 100644 --- a/telegram/handlers.go +++ b/telegram/handlers.go @@ -315,10 +315,14 @@ func (c *Client) updateMessageSendFailed(update *client.UpdateMessageSendFailed) // chat title changed func (c *Client) updateChatTitle(update *client.UpdateChatTitle) { + chat, user, _ := c.GetContactByID(update.ChatId, nil) + if c.Session.MUC && c.IsGroup(chat) { + return + } + gateway.SetNickname(c.jid, strconv.FormatInt(update.ChatId, 10), update.Title, c.xmpp) // set also the status (for group chats only) - chat, user, _ := c.GetContactByID(update.ChatId, nil) if user == nil { c.ProcessStatusUpdate(update.ChatId, update.Title, "chat", gateway.SPImmed(true)) } -- cgit v1.2.3