aboutsummaryrefslogtreecommitdiff
path: root/syncapi/sync
diff options
context:
space:
mode:
authorTill <2353100+S7evinK@users.noreply.github.com>2022-10-19 14:05:39 +0200
committerGitHub <noreply@github.com>2022-10-19 14:05:39 +0200
commite79bfd8fd55781783482cb45ae6d4e78062bb8ac (patch)
tree9b892d69efc71dd2259d04763037c23922cc68f3 /syncapi/sync
parent8cbe14bd6d985ceb2f7c098548a3fbeedfce2d55 (diff)
Get state deltas without filters (#2810)
This makes the following changes: - get state deltas without the user supplied filter, so we can actually "calculate" state transitions - closes `stmt` when using SQLite - Adds presence for users who newly joined a room, even if the syncing user already knows about the presence status (should fix https://github.com/matrix-org/complement/pull/516)
Diffstat (limited to 'syncapi/sync')
-rw-r--r--syncapi/sync/request.go19
1 files changed, 10 insertions, 9 deletions
diff --git a/syncapi/sync/request.go b/syncapi/sync/request.go
index 268ed70c..620dfdcd 100644
--- a/syncapi/sync/request.go
+++ b/syncapi/sync/request.go
@@ -91,15 +91,16 @@ func newSyncRequest(req *http.Request, device userapi.Device, syncDB storage.Dat
})
return &types.SyncRequest{
- Context: req.Context(), //
- Log: logger, //
- Device: &device, //
- Response: types.NewResponse(), // Populated by all streams
- Filter: filter, //
- Since: since, //
- Timeout: timeout, //
- Rooms: make(map[string]string), // Populated by the PDU stream
- WantFullState: wantFullState, //
+ Context: req.Context(), //
+ Log: logger, //
+ Device: &device, //
+ Response: types.NewResponse(), // Populated by all streams
+ Filter: filter, //
+ Since: since, //
+ Timeout: timeout, //
+ Rooms: make(map[string]string), // Populated by the PDU stream
+ WantFullState: wantFullState, //
+ MembershipChanges: make(map[string]struct{}), // Populated by the PDU stream
}, nil
}