public async Task<ClaimsIdentity> GenerateUserIdentityAsync(UserManager<ApplicationUser, int> manager, ApplicationUser user) { var userIdentity = await manager.CreateIdentityAsync(user, DefaultAuthenticationTypes.ApplicationCookie); // Add custom user claims here return userIdentity; }
public async Task<ClaimsIdentity> GenerateUserIdentityAsync(UserManager<IdentityUser> manager, IdentityUser user) { // Note the authenticationType must match the one defined in CookieAuthenticationOptions.AuthenticationType var userIdentity = await manager.CreateIdentityAsync(user, DefaultAuthenticationTypes.ApplicationCookie); // Add custom user claims here return userIdentity; }
public async Task<ClaimsIdentity> GenerateUserIdentityAsync(UserManager manager, User user) { var userIdentity = await manager.CreateIdentityAsync(user, DefaultAuthenticationTypes.ApplicationCookie); return userIdentity; }