Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(telegram/updates): handle UpdateChannelParticipant as qts seq #869

Merged
merged 1 commit into from Aug 29, 2022
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
5 changes: 2 additions & 3 deletions telegram/updates/classifier.go
Expand Up @@ -39,6 +39,8 @@ func isCommonQtsUpdate(u tg.UpdateClass) (qts int, ok bool) {
return u.Qts, true
case *tg.UpdateBotStopped:
return u.Qts, true
case *tg.UpdateChannelParticipant:
return u.Qts, true
}

return
Expand All @@ -60,9 +62,6 @@ func isChannelPtsUpdate(u tg.UpdateClass) (channelID int64, pts, ptsCount int, o
return u.ChannelID, u.Pts, u.PtsCount, true, nil
case *tg.UpdatePinnedChannelMessages:
return u.ChannelID, u.Pts, u.PtsCount, true, nil
case *tg.UpdateChannelParticipant:
// TODO: ptsCount 1?
return u.ChannelID, u.Qts, 0, true, nil
}

return
Expand Down