mirror of
https://github.com/ouchadam/small-talk.git
synced 2025-03-11 17:40:17 +01:00
fixing sync leak when changing to the profile page
This commit is contained in:
parent
a3dd5541e4
commit
5db1a87a38
@ -1,6 +1,7 @@
|
||||
package app.dapk.st.home
|
||||
|
||||
import androidx.lifecycle.viewModelScope
|
||||
import app.dapk.st.directory.state.ComponentLifecycle
|
||||
import app.dapk.st.directory.state.DirectorySideEffect
|
||||
import app.dapk.st.directory.state.DirectoryState
|
||||
import app.dapk.st.domain.StoreCleaner
|
||||
@ -122,7 +123,10 @@ internal class HomeViewModel(
|
||||
// do nothing
|
||||
}
|
||||
|
||||
Page.Profile -> profileViewModel.reset()
|
||||
Page.Profile -> {
|
||||
directoryState.dispatch(ComponentLifecycle.OnGone)
|
||||
profileViewModel.reset()
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user