When the record write succeeds, I want to show them a “purchase complete” fragment, and if the record is not created, I want to at least warn them with an error code.
Category: viewmodel
postValue() not working from MainActivity.kt
I have a View Model named “subsViewModel” that I’m storing subscription details for use by various fragments and MainActivity.kt. When a user authenticates with Google Firebase authentication, I want to store the user’s details into subsViewModel as shown below: Authenticate, Store Firebase User Information // Authenticate users: auth = Firebase.auth if (auth.currentUser == null){ //…(Continue Reading)