aboutsummaryrefslogtreecommitdiff
path: root/telegram/utils.go
diff options
context:
space:
mode:
Diffstat (limited to 'telegram/utils.go')
-rw-r--r--telegram/utils.go5
1 files changed, 4 insertions, 1 deletions
diff --git a/telegram/utils.go b/telegram/utils.go
index 87176fc..6d668b3 100644
--- a/telegram/utils.go
+++ b/telegram/utils.go
@@ -194,8 +194,11 @@ func (c *Client) ProcessStatusUpdate(chatID int64, status string, show string, a
}
}
+ cachedStatus, ok := c.cache.GetStatus(chatID)
if status == "" {
- if user != nil {
+ if ok {
+ show, status = cachedStatus.XMPP, cachedStatus.Description
+ } else if user != nil && user.Status != nil {
show, status = c.userStatusToText(user.Status, chatID)
} else {
show, status = "chat", chat.Title