facebook login have error of 'Email is required. '

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.
7 年 前
felix110 wrote:
Change FacebookProviderAuthorizer.cs class  ,add method RequestEmailFromFacebook,
and call this in the ParseClaims() method where claims.Contact.Email is set.
I have done this,but it still show the error of 'Email is required. '


I am having the same issue (Nop 3.9). Before I spend a lot of time trying to track this down, does anyone else have this problem/solution?

Additionally, this plugin no longer functions out of the box, however, implementing code changes referenced in this thread gets you part way there.

Basically, the current RequestEmailFromFacebook is passing back and Id with a lengthy numeric result...definitely not the email.
7 年 前
Quick Update:  I have tried 3 different profiles of facebook. Oddly, 2 profiles do return the email correctly, and 1 does not. There is something in the facebook profile that will affect whether the email is returned or not.  Basically, I am trying to determine what part of the contact profile email section in facebook is responsible for making the https://graph.facebook.com/me?fields=email&access_token=x line in RequestEmailFromFacebook return the email successfully.

Unrelated... I did want to mention to folks a workflow oversight in the plugin.
What may or may not be obvious to some is if you already have an account (email) in the nop database and then you attempt to log in with facebook you get a "already registered email" message.  It appears this plugin ONLY works if you accept new clients/customers and they initially use the facebook login approach to complete their registration and have no record in the Customer table of nop already. If they register on the store (normal) and later try to login with facebook, the pairing doesn't exist, and nop tries to register with the same email and it fails.
This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.