Update chat title in chats cache
This commit is contained in:
parent
739fc4110a
commit
f8ad8c0204
|
@ -294,8 +294,13 @@ func (c *Client) updateChatTitle(update *client.UpdateChatTitle) {
|
|||
gateway.SetNickname(c.jid, strconv.FormatInt(update.ChatId, 10), update.Title, c.xmpp)
|
||||
|
||||
// set also the status (for group chats only)
|
||||
_, user, _ := c.GetContactByID(update.ChatId, nil)
|
||||
chat, user, _ := c.GetContactByID(update.ChatId, nil)
|
||||
if user == nil {
|
||||
c.ProcessStatusUpdate(update.ChatId, update.Title, "chat", gateway.SPImmed(true))
|
||||
}
|
||||
|
||||
// update chat title in the cache
|
||||
if chat != nil {
|
||||
chat.Title = update.Title
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue