I was using ASP.NET MVC 5 and all was working fine, now I'm working with ASP.NET Core and the social login with Facebook is not getting the email. I have tested with my account and others as well. I'm using:
"Microsoft.AspNet.Authentication.Facebook": "1.0.0-rc1-final"
This is the code in the Account Controller:
// REVIEW: handle case where email not in claims?
var email = loginInfo.ExternalPrincipal.FindFirstValue(ClaimTypes.Email);
Startup.cs Example:
app.UseFacebookAuthentication(options =>
{
options.AppId = "**********";
options.AppSecret = "********";
});
Any ideas how to fix it?