diff --git a/app/src/main/java/com/gdsc_cau/vridge/login/LoginViewModel.kt b/app/src/main/java/com/gdsc_cau/vridge/login/LoginViewModel.kt index 8bd9516..93e9965 100644 --- a/app/src/main/java/com/gdsc_cau/vridge/login/LoginViewModel.kt +++ b/app/src/main/java/com/gdsc_cau/vridge/login/LoginViewModel.kt @@ -11,7 +11,10 @@ import dagger.hilt.android.lifecycle.HiltViewModel import javax.inject.Inject @HiltViewModel -class LoginViewModel @Inject constructor(): ViewModel() { +class LoginViewModel +@Inject +constructor() : + ViewModel() { val isLoggedIn = MutableLiveData(false) fun tryGoogleLogin(signInLauncher: ActivityResultLauncher) { @@ -19,11 +22,12 @@ class LoginViewModel @Inject constructor(): ViewModel() { } fun onSignInResult(result: FirebaseAuthUIAuthenticationResult) { - if (result.resultCode == ComponentActivity.RESULT_OK - && FirebaseAuthUtil.getCurrentUser() != null) { + if (result.resultCode == ComponentActivity.RESULT_OK && + FirebaseAuthUtil.getCurrentUser() != null + ) { isLoggedIn.postValue(true) } else { // TODO: Show Snack Bar? } } -} \ No newline at end of file +}