aboutsummaryrefslogtreecommitdiff
path: root/shared/src/commonMain/kotlin/mx/trackermap/TrackerMap
diff options
context:
space:
mode:
Diffstat (limited to 'shared/src/commonMain/kotlin/mx/trackermap/TrackerMap')
-rw-r--r--shared/src/commonMain/kotlin/mx/trackermap/TrackerMap/controllers/SessionController.kt2
1 files changed, 2 insertions, 0 deletions
diff --git a/shared/src/commonMain/kotlin/mx/trackermap/TrackerMap/controllers/SessionController.kt b/shared/src/commonMain/kotlin/mx/trackermap/TrackerMap/controllers/SessionController.kt
index 3c213d5..237f1a3 100644
--- a/shared/src/commonMain/kotlin/mx/trackermap/TrackerMap/controllers/SessionController.kt
+++ b/shared/src/commonMain/kotlin/mx/trackermap/TrackerMap/controllers/SessionController.kt
@@ -18,6 +18,7 @@ class SessionController(
private val usersApi: UsersApi
) {
sealed class LoginState {
+ object Nothing: LoginState()
object Loading: LoginState()
object EmailMissing : LoginState()
object PasswordMissing : LoginState()
@@ -51,6 +52,7 @@ class SessionController(
loginStateFlow.value = LoginState.Success
} catch (e: Exception) {
Log.d("LoginViewModel", "No session")
+ loginStateFlow.value = LoginState.Nothing
}
}
}