diff options
author | Till <2353100+S7evinK@users.noreply.github.com> | 2022-04-30 00:07:50 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-04-30 00:07:50 +0200 |
commit | 987d7adc5d4e34827759b206ac4cc17cce78e221 (patch) | |
tree | 2ac941ddf6199e801e76bd2bc9ec47c05a8f453f | |
parent | 31799a3b2a733192a656cfa77662599bd1568bdc (diff) |
Return "to", if we didn't return any presence events (#2407)
Return correct stream position, if we didn't return any presence events
-rw-r--r-- | syncapi/streams/stream_presence.go | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/syncapi/streams/stream_presence.go b/syncapi/streams/stream_presence.go index a84d1987..35ce53cb 100644 --- a/syncapi/streams/stream_presence.go +++ b/syncapi/streams/stream_presence.go @@ -145,6 +145,10 @@ func (p *PresenceStreamProvider) IncrementalSync( p.cache.Store(cacheKey, presence) } + if len(req.Response.Presence.Events) == 0 { + return to + } + return lastPos } |