diff --git a/app/src/main/kotlin/com/wire/android/ui/calling/SharedCallingViewModel.kt b/app/src/main/kotlin/com/wire/android/ui/calling/SharedCallingViewModel.kt index 0296206a34e..8951611c447 100644 --- a/app/src/main/kotlin/com/wire/android/ui/calling/SharedCallingViewModel.kt +++ b/app/src/main/kotlin/com/wire/android/ui/calling/SharedCallingViewModel.kt @@ -59,6 +59,7 @@ import kotlinx.coroutines.CoroutineScope import kotlinx.coroutines.flow.SharedFlow import kotlinx.coroutines.flow.SharingStarted import kotlinx.coroutines.flow.collectLatest +import kotlinx.coroutines.flow.distinctUntilChanged import kotlinx.coroutines.flow.filterIsInstance import kotlinx.coroutines.flow.first import kotlinx.coroutines.flow.flowOn @@ -174,7 +175,7 @@ class SharedCallingViewModel @AssistedInject constructor( } private suspend fun observeParticipants(sharedFlow: SharedFlow) { - sharedFlow.collect { call -> + sharedFlow.distinctUntilChanged().collectLatest { call -> call?.let { callState = callState.copy( isMuted = it.isMuted, diff --git a/gradle/libs.versions.toml b/gradle/libs.versions.toml index de5ca6da0d6..7ced6992d09 100644 --- a/gradle/libs.versions.toml +++ b/gradle/libs.versions.toml @@ -46,8 +46,8 @@ androidx-compose-runtime = "1.6.7" # Compose composeBom = "2024.06.00" -compose-foundation = "1.7.0-beta04" # remove when composeBom contains new stable version of BasicTextField2 -compose-material-android = "1.7.0-beta04" # remove when composeBom contains new stable version of BasicTextField2 +compose-foundation = "1.7.0-beta05" # remove when composeBom contains new stable version of BasicTextField2 +compose-material-android = "1.7.0-beta05" # remove when composeBom contains new stable version of BasicTextField2 compose-activity = "1.9.0" compose-compiler = "1.5.11" compose-constraint = "1.0.1"