mirror of
https://github.com/hoernschen/dendrite.git
synced 2025-08-02 14:12:47 +00:00
Don't send account data or receipts for left/forgotten rooms (#2382)
* Only include account data and receipts for rooms in a complete sync that we care about * Fix global account data
This commit is contained in:
parent
66b397b3c6
commit
dca4afd2f0
3 changed files with 29 additions and 0 deletions
|
@ -53,6 +53,12 @@ func (p *AccountDataStreamProvider) IncrementalSync(
|
|||
|
||||
// Iterate over the rooms
|
||||
for roomID, dataTypes := range dataTypes {
|
||||
// For a complete sync, make sure we're only including this room if
|
||||
// that room was present in the joined rooms.
|
||||
if from == 0 && roomID != "" && !req.IsRoomPresent(roomID) {
|
||||
continue
|
||||
}
|
||||
|
||||
// Request the missing data from the database
|
||||
for _, dataType := range dataTypes {
|
||||
dataReq := userapi.QueryAccountDataRequest{
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue