Rename fun.
This commit is contained in:
parent
43df6cfbb8
commit
3e62b967b5
1 changed files with 3 additions and 3 deletions
|
|
@ -93,10 +93,10 @@ class RootFlowNode @AssistedInject constructor(
|
||||||
if (isLoggedIn) {
|
if (isLoggedIn) {
|
||||||
tryToRestoreLatestSession(
|
tryToRestoreLatestSession(
|
||||||
onSuccess = { switchToLoggedInFlow(it) },
|
onSuccess = { switchToLoggedInFlow(it) },
|
||||||
onFailure = { switchToLogoutFlow() }
|
onFailure = { switchToNotLoggedInFlow() }
|
||||||
)
|
)
|
||||||
} else {
|
} else {
|
||||||
switchToLogoutFlow()
|
switchToNotLoggedInFlow()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
.launchIn(lifecycleScope)
|
.launchIn(lifecycleScope)
|
||||||
|
|
@ -106,7 +106,7 @@ class RootFlowNode @AssistedInject constructor(
|
||||||
backstack.safeRoot(NavTarget.LoggedInFlow(sessionId))
|
backstack.safeRoot(NavTarget.LoggedInFlow(sessionId))
|
||||||
}
|
}
|
||||||
|
|
||||||
private fun switchToLogoutFlow() {
|
private fun switchToNotLoggedInFlow() {
|
||||||
matrixClientsHolder.removeAll()
|
matrixClientsHolder.removeAll()
|
||||||
backstack.safeRoot(NavTarget.NotLoggedInFlow)
|
backstack.safeRoot(NavTarget.NotLoggedInFlow)
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue