aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBohdan Horbeshko <bodqhrohro@gmail.com>2022-01-17 20:19:59 +0300
committerBohdan Horbeshko <bodqhrohro@gmail.com>2022-01-17 20:19:59 +0300
commite260668f91ee7a1a1fb8ecaa159c6795b9db2eb2 (patch)
tree62d5ecee40867f71c1df703fbc8d5a03ccb512dd
parent3db096734f38d5bde745cbb46b2c022473a6a063 (diff)
Revert "Don't subscribe to chat updates with no conversations"
This reverts commit 23f2a85301f2ee5af867fa774a406cf308733714. (Why did I add this at all, lol.)
-rw-r--r--telegram/handlers.go6
1 files changed, 1 insertions, 5 deletions
diff --git a/telegram/handlers.go b/telegram/handlers.go
index bb4beff..b76ea23 100644
--- a/telegram/handlers.go
+++ b/telegram/handlers.go
@@ -156,11 +156,7 @@ func (c *Client) updateNewChat(update *client.UpdateNewChat) {
isChannel = typeSupergroup.IsChannel
}
- // don't subscribe to channel posters
- if !((isChannel && update.Chat.LastReadInboxMessageID == 0) ||
- // don't subscribe to chats with no conversation
- // (manual adding will trigger a subscribe anyway)
- (update.Chat.LastReadInboxMessageID == 0 && update.Chat.LastReadOutboxMessageID == 0)) {
+ if !(isChannel && update.Chat.LastReadInboxMessageID == 0) {
gateway.SendPresence(
c.xmpp,
c.jid,