Fix / Syncs breaking on dendrite
This commit is contained in:
parent
7521a0d3ae
commit
b7a89f4055
|
@ -456,7 +456,7 @@ internal class RoomSyncHandler @Inject constructor(private val readReceiptHandle
|
|||
}
|
||||
|
||||
private fun handleRoomAccountDataEvents(realm: Realm, roomId: String, accountData: RoomSyncAccountData) {
|
||||
for (event in accountData.events) {
|
||||
accountData.events?.forEach { event ->
|
||||
val eventType = event.getClearType()
|
||||
if (eventType == EventType.TAG) {
|
||||
val content = event.getClearContent().toModel<RoomTagContent>()
|
||||
|
|
|
@ -25,5 +25,5 @@ internal data class RoomSyncAccountData(
|
|||
/**
|
||||
* List of account data events (array of Event).
|
||||
*/
|
||||
@Json(name = "events") val events: List<Event> = emptyList()
|
||||
@Json(name = "events") val events: List<Event>? = emptyList()
|
||||
)
|
||||
|
|
|
@ -26,5 +26,5 @@ internal data class RoomSyncEphemeral(
|
|||
/**
|
||||
* List of ephemeral events (array of Event).
|
||||
*/
|
||||
@Json(name = "events") val events: List<Event> = emptyList()
|
||||
@Json(name = "events") val events: List<Event>? = emptyList()
|
||||
)
|
||||
|
|
|
@ -27,5 +27,5 @@ internal data class RoomSyncState(
|
|||
/**
|
||||
* List of state events (array of Event). The resulting state corresponds to the *start* of the timeline.
|
||||
*/
|
||||
@Json(name = "events") val events: List<Event> = emptyList()
|
||||
@Json(name = "events") val events: List<Event>? = emptyList()
|
||||
)
|
||||
|
|
|
@ -27,7 +27,7 @@ internal data class RoomSyncTimeline(
|
|||
/**
|
||||
* List of events (array of Event).
|
||||
*/
|
||||
@Json(name = "events") val events: List<Event> = emptyList(),
|
||||
@Json(name = "events") val events: List<Event>? = emptyList(),
|
||||
|
||||
/**
|
||||
* Boolean which tells whether there are more events on the server
|
||||
|
|
Loading…
Reference in New Issue