No need to have list of public room here
This commit is contained in:
parent
79c9c7105e
commit
07d2d29212
|
@ -29,7 +29,7 @@ data class PublicRoomsViewState(
|
|||
// Store cumul of pagination result
|
||||
val publicRooms: List<PublicRoom> = emptyList(),
|
||||
// Current pagination request
|
||||
val asyncPublicRoomsRequest: Async<List<PublicRoom>> = Uninitialized,
|
||||
val asyncPublicRoomsRequest: Async<Unit> = Uninitialized,
|
||||
// True if more result are available server side
|
||||
val hasMore: Boolean = false,
|
||||
// Set of joined roomId,
|
||||
|
|
|
@ -171,7 +171,7 @@ class RoomDirectoryViewModel @AssistedInject constructor(@Assisted initialState:
|
|||
|
||||
setState {
|
||||
copy(
|
||||
asyncPublicRoomsRequest = Success(data.chunk!!),
|
||||
asyncPublicRoomsRequest = Success(Unit),
|
||||
// It's ok to append at the end of the list, so I use publicRooms.size()
|
||||
publicRooms = publicRooms.appendAt(data.chunk!!, publicRooms.size)
|
||||
// Rageshake #8206 tells that we can have several times the same room
|
||||
|
|
Loading…
Reference in New Issue