chore: fix some crash and performance issues (#45)
Reviewed-on: #45
This commit was merged in pull request #45.
This commit is contained in:
@@ -695,8 +695,7 @@ fun NewRequests(requests: List<Room>) {
|
||||
@Composable
|
||||
fun ChatRoom(room: Room, onClick: () -> Unit) {
|
||||
val profileCache = LocalProfileCache.current
|
||||
val roomState by room.uiStateFlow(profileCache)
|
||||
.collectAsStateWithLifecycle(RoomUiState())
|
||||
val roomState by room.uiStateFlow(profileCache).collectAsStateWithLifecycle(RoomUiState())
|
||||
|
||||
ListItem(
|
||||
modifier = Modifier.clickable(onClick = onClick),
|
||||
|
||||
@@ -397,7 +397,7 @@ fun ContactListItem(
|
||||
supportingContent = { Text(text = pubkey.short()) },
|
||||
content = {
|
||||
Text(
|
||||
text = profile?.name ?: "",
|
||||
text = profile?.name ?: "Unknown",
|
||||
style = MaterialTheme.typography.titleMediumEmphasized,
|
||||
)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user