diff --git a/crates/matrix-sdk/src/event_cache/caches/thread/pagination.rs b/crates/matrix-sdk/src/event_cache/caches/thread/pagination.rs index 7f28e81f1..b52ad2457 100644 --- a/crates/matrix-sdk/src/event_cache/caches/thread/pagination.rs +++ b/crates/matrix-sdk/src/event_cache/caches/thread/pagination.rs @@ -114,7 +114,8 @@ impl PaginatedCache for ThreadEventCacheWrapper { let prev_first_chunk = state.thread_linked_chunk().first_chunk(); - // The first chunk is not a gap, we can load its previous chunk. + // If we are here, it means all gaps have been resolved (see the `if` block + // above). So the first chunk is not a gap, we can load its previous chunk. let linked_chunk_id = LinkedChunkId::Thread(&state.room_id, &state.thread_id); let new_first_chunk = match state .store