From 3de07ad550776a57e96399660c0ccd9c58dafcf3 Mon Sep 17 00:00:00 2001 From: Tulir Asokan Date: Tue, 24 Apr 2018 23:52:31 +0300 Subject: Add tests for syncer and fix some bugs --- matrix/sync.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'matrix/sync.go') diff --git a/matrix/sync.go b/matrix/sync.go index 8ad7ad5..8ff3d39 100644 --- a/matrix/sync.go +++ b/matrix/sync.go @@ -74,7 +74,8 @@ func (s *GomuksSyncer) ProcessResponse(res *gomatrix.RespSync, since string) (er for roomID, roomData := range res.Rooms.Leave { room := s.Session.GetRoom(roomID) - s.processSyncEvents(room, roomData.Timeline.Events, true, true) + s.processSyncEvents(room, roomData.State.Events, true, true) + s.processSyncEvents(room, roomData.Timeline.Events, false, false) if len(room.PrevBatch) == 0 { room.PrevBatch = roomData.Timeline.PrevBatch -- cgit v1.2.3