Improve fetch members performance, relax regexes for validating ids (#964)
* Fetched `RoomMembers` are mapped in parallel * Add horizontal padding to room/user name in room details screen * Relax User & Event id regex matches --------- Co-authored-by: ElementBot <benoitm+elementbot@element.io>
This commit is contained in:
parent
05f7037939
commit
dbec1a0a60
32 changed files with 79 additions and 62 deletions
|
|
@ -18,6 +18,7 @@ package io.element.android.libraries.matrix.impl.room
|
|||
|
||||
import io.element.android.libraries.core.coroutine.CoroutineDispatchers
|
||||
import io.element.android.libraries.core.coroutine.childScope
|
||||
import io.element.android.libraries.core.coroutine.parallelMap
|
||||
import io.element.android.libraries.matrix.api.core.EventId
|
||||
import io.element.android.libraries.matrix.api.core.ProgressCallback
|
||||
import io.element.android.libraries.matrix.api.core.RoomId
|
||||
|
|
@ -168,7 +169,7 @@ class RustMatrixRoom(
|
|||
val currentMembers = currentState.roomMembers()
|
||||
_membersStateFlow.value = MatrixRoomMembersState.Pending(prevRoomMembers = currentMembers)
|
||||
runCatching {
|
||||
innerRoom.members().map(RoomMemberMapper::map)
|
||||
innerRoom.members().parallelMap(RoomMemberMapper::map)
|
||||
}.map {
|
||||
_membersStateFlow.value = MatrixRoomMembersState.Ready(it)
|
||||
}.onFailure {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue