Answer the question
In order to leave comments, you need to log in
Answer the question
In order to leave comments, you need to log in
mAuth = FirebaseAuth.getInstance();
FirebaseUser user = mAuth.getCurrentUser();
if (user != null) {
Intent intent = new Intent(ACTIVITY.this, User.class);
startActivity(intent);
finish();
}
You make the main activity a conditional LoginActivity, at the start you check whether you are logged in or not, if yes, then start the main activity and do finish for this one, if not, then leave the current activity, when you enter the login and successful authorization, you start the main one and close this one
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question