firebase / firebase-js-sdk

Firebase Javascript SDK
https://firebase.google.com/docs/web/setup
Other
4.83k stars 891 forks source link

Signing in using a disabled account, using signInWithPopup, returns an 'Internal Error' #245

Closed pmullot closed 4 years ago

pmullot commented 7 years ago

Version info

Angular: 4.4.3

Firebase:

AngularFire: 4.0.0-rc.2

Other (e.g. Ionic/Cordova, Node, browser, operating system): no

How to reproduce these conditions

When you try to sign in using a Disabled account (via the Firebase Console), using signInWithPopup, it returns an 'Internal Error'.

Steps to set up and reproduce With a typical login function, as described in all examples and tutorials

login() {
    const provider = new firebase.auth.GoogleAuthProvider();
    this.afAuth.auth.signInWithPopup(provider)
        .then(credential =>  {
            // use credential observable to get user data ...
        // with a disabled user, this is not reached
        })
        .catch(error => {
          console.log(error);
          // error =  {code: "auth/internal-error", message: "An internal error has occurred."}
        });
}

Expected behavior

Returned error should specify "User disabled" or something similar

Actual behavior

Returned error isn't specific enough. It's also misguiding since it refers to an internal error {code: "auth/internal-error", message: "An internal error has occurred."}

google-oss-bot commented 7 years ago

Hey there! I couldn't figure out what this issue is about, so I've labeled it for a human to triage. Hang tight.

google-oss-bot commented 7 years ago

Hmmm this issue does not seem to follow the issue template. Make sure you provide all the required information.

rommelpe commented 5 years ago

@pmullot, I believed this issue was fixed in the tagged commit. I was able to confirm it with my sample repro using Angular:4.4.3 with @angular/fire:5.0.0 (the old AngularFire was depreciated so I’ve used the older version of new @angular/fire). Let us know if you are still having issues.

google-oss-bot commented 4 years ago

Hey @pmullot. We need more information to resolve this issue but there hasn't been an update in 7 days. I'm marking the issue as stale and if there are no new updates in the next 3 days I will close it automatically.

If you have more information that will help us get to the bottom of this, just add a comment!

google-oss-bot commented 4 years ago

Since there haven't been any recent updates here, I am going to close this issue.

@pmullot if you're still experiencing this problem and want to continue the discussion just leave a comment here and we are happy to re-open this.