Skip to content

Commit b2cb345

Browse files
committed
Notify viewModel as soon as the bottom sheet triggers the view action event
1 parent 069a936 commit b2cb345

File tree

1 file changed

+1
-7
lines changed

1 file changed

+1
-7
lines changed

stream-chat-android-compose/src/main/java/io/getstream/chat/android/compose/ui/channel/info/ChannelInfoMemberInfoModalSheet.kt

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -90,14 +90,8 @@ internal fun ChannelInfoMemberInfoModalSheet(
9090
ChannelInfoMemberInfoModalSheetContent(
9191
state = state,
9292
onViewAction = { action ->
93-
// We need to handle the dismissal of the sheet ourselves
94-
// because we are hiding it manually.
93+
viewModel.onViewAction(action)
9594
scope.launch { sheetState.hide() }
96-
.invokeOnCompletion {
97-
if (!sheetState.isVisible) {
98-
viewModel.onViewAction(action)
99-
}
100-
}
10195
},
10296
)
10397
}

0 commit comments

Comments
 (0)