Puts marked as read on chat to an IO thread
This commit is contained in:
@@ -254,12 +254,14 @@ fun NormalChatNote(
|
|||||||
|
|
||||||
if (routeForLastRead != null) {
|
if (routeForLastRead != null) {
|
||||||
LaunchedEffect(key1 = routeForLastRead) {
|
LaunchedEffect(key1 = routeForLastRead) {
|
||||||
|
launch(Dispatchers.IO) {
|
||||||
val createdAt = note.createdAt()
|
val createdAt = note.createdAt()
|
||||||
if (createdAt != null) {
|
if (createdAt != null) {
|
||||||
accountViewModel.account.markAsRead(routeForLastRead, createdAt)
|
accountViewModel.account.markAsRead(routeForLastRead, createdAt)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
Column() {
|
Column() {
|
||||||
val modif = remember {
|
val modif = remember {
|
||||||
|
|||||||
Reference in New Issue
Block a user