mirror of
https://github.com/vector-im/element-android.git
synced 2024-11-16 02:05:06 +08:00
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
|
// Store cumul of pagination result
|
||||||
val publicRooms: List<PublicRoom> = emptyList(),
|
val publicRooms: List<PublicRoom> = emptyList(),
|
||||||
// Current pagination request
|
// Current pagination request
|
||||||
val asyncPublicRoomsRequest: Async<List<PublicRoom>> = Uninitialized,
|
val asyncPublicRoomsRequest: Async<Unit> = Uninitialized,
|
||||||
// True if more result are available server side
|
// True if more result are available server side
|
||||||
val hasMore: Boolean = false,
|
val hasMore: Boolean = false,
|
||||||
// Set of joined roomId,
|
// Set of joined roomId,
|
||||||
|
@ -171,7 +171,7 @@ class RoomDirectoryViewModel @AssistedInject constructor(@Assisted initialState:
|
|||||||
|
|
||||||
setState {
|
setState {
|
||||||
copy(
|
copy(
|
||||||
asyncPublicRoomsRequest = Success(data.chunk!!),
|
asyncPublicRoomsRequest = Success(Unit),
|
||||||
// It's ok to append at the end of the list, so I use publicRooms.size()
|
// It's ok to append at the end of the list, so I use publicRooms.size()
|
||||||
publicRooms = publicRooms.appendAt(data.chunk!!, publicRooms.size)
|
publicRooms = publicRooms.appendAt(data.chunk!!, publicRooms.size)
|
||||||
// Rageshake #8206 tells that we can have several times the same room
|
// Rageshake #8206 tells that we can have several times the same room
|
||||||
|
Loading…
Reference in New Issue
Block a user