mirror of
https://dev.narayana.im/narayana/telegabber.git
synced 2026-08-05 04:07:07 +00:00
Set "complete" attribute for requests beyond limits for clearly non-RSM reasons
This commit is contained in:
parent
17f617e15d
commit
623af72cdd
1 changed files with 2 additions and 0 deletions
|
|
@ -2425,6 +2425,7 @@ func handleSetQueryMAM2(s xmpp.Sender, iq *stanza.IQ, query *extensions.MAM2Quer
|
|||
// don't allow to fetch far beyond the quota
|
||||
if !endTime.IsZero() && endTime.Before(quotaTs) {
|
||||
beyond = true
|
||||
complete = true
|
||||
}
|
||||
if (!startTime.IsZero() && startTime.Before(quotaTs)) || startTime.IsZero() {
|
||||
startTime = quotaTs
|
||||
|
|
@ -2448,6 +2449,7 @@ func handleSetQueryMAM2(s xmpp.Sender, iq *stanza.IQ, query *extensions.MAM2Quer
|
|||
overallyLastMessageId = lastMessageId
|
||||
} else {
|
||||
beyond = true
|
||||
complete = true
|
||||
}
|
||||
} else {
|
||||
newestMessage, newestMessageErr := session.GetPreviousMessage(toID, 0)
|
||||
|
|
|
|||
Loading…
Reference in a new issue