angularfire icon indicating copy to clipboard operation
angularfire copied to clipboard

Facebook login authentication problem

Open samirthebti opened this issue 10 years ago • 5 comments

I use this code in main.ts :

bootstrap(MyApp, [
  APP_ROUTER_PROVIDERS,
  HTTP_PROVIDERS,
  FIREBASE_PROVIDERS,
  defaultFirebase({
    apiKey: "",
    authDomain: "",
    databaseURL: "",
    storageBucket: "",
  }),
  firebaseAuthConfig({
    method: AuthMethods.Password
  })
]).catch(err => console.error(err));

and i have this methode for facebook login

loginFacebook(){
 this.af.auth.login({
      provider: AuthProviders.Facebook,
      method: AuthMethods.OAuthToken,
    });
    console.log(" facebook login  ");

  }

and the facebook authentification d'ont work how i can see the erreurs logs ?

samirthebti avatar Jul 01 '16 00:07 samirthebti

i get this error :

you must include credentials to use this auth method.

samirthebti avatar Jul 02 '16 22:07 samirthebti

@samirthebti Sorry for the delay on this issue. Can you create a plnkr?

davideast avatar Jul 15 '16 18:07 davideast

Never mind, I just reproduced this myself. This is a bug, we'll get it fixed in the next release.

davideast avatar Jul 15 '16 18:07 davideast

@samirthebti with method: AuthMethods.Popup or method: AuthMethods.Redirect I have it working, but I do get same error with method: AuthMethods.OAuthToken

Ronsku avatar Jul 16 '16 19:07 Ronsku

@Ronsku is correct.

Using AuthMethods.OAuthToken is an incorrect option.

davideast avatar Aug 22 '16 23:08 davideast