title: I want to display the Flushbar when wrong credentials are entered but instead the execution stops of the following section
body: <pre><code>if (_loginFormKey.currentState.validate()) {
     try{
        showAlertDialog(context);
        Navigator.of(context).pop();
        FirebaseAuth.instance.signInWithEmailAndPassword(email: email, password: pass)
        .then((result){
        User user = result.user;
        if(user == null )
         {
            // showAlertDialogs(context);
             setState(() {
             Flushbar(
                    borderRadius: 8.0,
                    title: &quot;Invalid Password/Email&quot;,
                            message:
                                &quot;Please enter correct Email and Password&quot;,
                            flushbarPosition: FlushbarPosition.BOTTOM,
                            flushbarStyle: FlushbarStyle.FLOATING,
                            reverseAnimationCurve: Curves.decelerate,
                            forwardAnimationCurve: Curves.bounceIn,
                            backgroundColor: Colors.black,
                            mainButton: FlatButton(
                                onPressed: () {
                                  Navigator.pop(context);
                                },
                                child: Text(
                                  &quot;OK&quot;,
                                  style: TextStyle(color: Colors.white),
                                )),
                            boxShadows: [
                              BoxShadow(
                                  color: Colors.blue[800],
                                  offset: Offset(0.0, 5.0),
                                  blurRadius: 8.0)
                            ],
                            margin:
                            EdgeInsets.only(bottom: 8, left: 8, right: 8),
                            isDismissible: true,
                            duration: Duration(seconds: 10),
                            icon: Icon(
                              Icons.error_outline,
                              color: Colors.white,
                            ),
                          )..show(context);
                                });
                          }
                             else {
                                showAlertDialog(context);
                                Navigator.pushAndRemoveUntil(context, _homeRoute(), (_) =&gt; false);
                                //  showAlertDialogs(context);
  
                                 }
                               }
                              );
                             }
                             catch(e)
                             {
                               print(e);
                             }
           }
  </code></pre>
  <p>this in the stack trace when wrong credentials are given as input</p>
  <pre><code>/BiChannelGoogleApi( 3302): [FirebaseAuth: ] getGoogleApiForMethod() returned Gms:   com.google.firebase.auth.api.internal.zzaq@f17202f
  E/flutter ( 3302): [ERROR:flutter/lib/ui/ui_dart_state.cc(171)] Unhandled Exception:     [firebase_auth/wrong-password] The password is invalid or the user does not have a password.
  E/flutter ( 3302): #0      catchPlatformException 
  package:firebase_auth_platform_interface/…/utils/exception.dart:20
  E/flutter ( 3302): #1      _rootRunUnary  (dart:async/zone.dart:1198:47)
  E/flutter ( 3302): #2      _CustomZone.runUnary  (dart:async/zone.dart:1100:19)
  E/flutter ( 3302): #3      _FutureListener.handleError  (dart:async/future_impl.dart:160:20)
  E/flutter ( 3302): #4      Future._propagateToListeners.handleError   (dart:async/future_impl.dart:708:47)
  E/flutter ( 3302): #5      Future._propagateToListeners  (dart:async/future_impl.dart:729:24)
  E/flutter ( 3302): #6      Future._completeError  (dart:async/future_impl.dart:537:5)
  E/flutter ( 3302): #7      _AsyncAwaitCompleter.completeError  (dart:async-  patch/async_patch.dart:47:15)
  </code></pre>
  <p>once the <code>_loginFormKey</code> is validated ; the <code>signInWithEmailAndPassword()</code> is called and user is signed in if credentials are correct, but if they are wrong an alert bar (<code>Flushbar</code>) should be shown on the bottom of the screen. but somehow this section of the code is ignored by flutter.</p>
  <p>*Please note i want to show the <code>Flushbar</code> context when wrong credentials are given as input</p>
  <p>also question: Does <code>FirebaseAuth</code> return a <code>user</code> when wrong password is given as an input? or the <code>user</code> is <code>null</code>?</p>
  <p>*Note: i am new to <code>Firebase</code> please forgive if i do something wrong!!!!</p>