aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorDaniel Gultsch <daniel@gultsch.de>2017-01-12 20:56:55 +0100
committerDaniel Gultsch <daniel@gultsch.de>2017-01-12 20:56:55 +0100
commitc03e3b59652678721353a290449d39996faeb8fa (patch)
tree0656ee8477310b10c9f3542b7c579319782de8a3 /src
parentfd7216b6a06149f96fcc74732d93d871f704bc3e (diff)
don't include 'before' reference in mam queries bound by timestamp
Diffstat (limited to 'src')
-rw-r--r--src/main/java/eu/siacs/conversations/services/MessageArchiveService.java4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/main/java/eu/siacs/conversations/services/MessageArchiveService.java b/src/main/java/eu/siacs/conversations/services/MessageArchiveService.java
index 39d4b44d..a352ea8a 100644
--- a/src/main/java/eu/siacs/conversations/services/MessageArchiveService.java
+++ b/src/main/java/eu/siacs/conversations/services/MessageArchiveService.java
@@ -111,7 +111,9 @@ public class MessageArchiveService implements OnAdvancedStreamFeaturesLoaded {
return null;
}
final Query query = new Query(conversation, start, end,PagingOrder.REVERSE);
- query.reference = conversation.getFirstMamReference();
+ if (start==0) {
+ query.reference = conversation.getFirstMamReference();
+ }
this.queries.add(query);
this.execute(query);
return query;