No need to launch a coroutine to send the first value.

This commit is contained in:
Benoit Marty 2024-09-24 16:01:58 +02:00
parent 1309d04649
commit d14361760b

View file

@ -116,10 +116,8 @@ class RustMatrixRoom(
}
override val roomTypingMembersFlow: Flow<List<UserId>> = mxCallbackFlow {
launch {
val initial = emptyList<UserId>()
channel.trySend(initial)
}
val initial = emptyList<UserId>()
channel.trySend(initial)
innerRoom.subscribeToTypingNotifications(object : TypingNotificationsListener {
override fun call(typingUserIds: List<String>) {
channel.trySend(