From 8208464653469e138a3688da41715b83967444dd Mon Sep 17 00:00:00 2001 From: Bruno Windels Date: Tue, 2 Mar 2021 19:37:11 +0100 Subject: [PATCH] only log and clear when actually needed --- src/matrix/room/timeline/persistence/GapWriter.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/matrix/room/timeline/persistence/GapWriter.js b/src/matrix/room/timeline/persistence/GapWriter.js index 6b4f21df..899bc16a 100644 --- a/src/matrix/room/timeline/persistence/GapWriter.js +++ b/src/matrix/room/timeline/persistence/GapWriter.js @@ -235,7 +235,7 @@ export class GapWriter { nonOverlappingEvents, neighbourFragmentEntry } = await this._findOverlappingEvents(fragmentEntry, chunk, txn, log); - if (!neighbourFragmentEntry && nonOverlappingEvents.length === 0) { + if (!neighbourFragmentEntry && nonOverlappingEvents.length === 0 && typeof end === "string") { log.log("hit #160, clearing token", log.level.Warn); end = null; }