Click here to Skip to main content
15,887,344 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hello, i have the following code which is not working:

<pre> navigateUser() async {
    // checking whether user already loggedIn or not
    if (_auth.currentUser != null) {
      && FirebaseAuth.instance.currentUser.reload() != null
      Timer(


The Line which is not working is this:
&& FirebaseAuth.instance.currentUser.reload() != null


How could i change this, i want to reaload the Firebase.Auth.Status

What I have tried:

I searched on stackoverflow, but didnt found any answer
Posted
Updated 24-Jan-21 21:23pm

1 solution

Quote:
JavaScript
if (_auth.currentUser != null) {
      && FirebaseAuth.instance.currentUser.reload() != null
The line starting with && is not a valid statement. Presumably you wanted to make that part of the if condition, in which case it need to be inside the brackets on that line:
JavaScript
if (_auth.currentUser != null && FirebaseAuth.instance.currentUser.reload() != null) {
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900