I am using Asp.Net MVC OAuth login with facebook and google and strange thing that at some period it doesnot work
var externalIdentity =
HttpContext.GetOwinContext()
.Authentication.GetExternalIdentityAsync(DefaultAuthenticationTypes.ExternalCookie);
var loginInfo = await AuthenticationManager.GetExternalLoginInfoAsync();
if (loginInfo == null)
{
return RedirectToAction("Login");
}
Seems here it cant get user info and redirect to login page. I cant figure out why or what can cause that. I also have two slots beta and production.
So any suggestion or maybe somebody already have that and found way how to fix that?