Impliment the StayLoggedIn
This commit is contained in:
@@ -48,12 +48,10 @@ namespace MistoxWebsite.Server.Controllers {
|
||||
|
||||
await HttpContext.SignInAsync(
|
||||
CookieAuthenticationDefaults.AuthenticationScheme,
|
||||
new ClaimsPrincipal( new ClaimsIdentity( claims, "serverAuth" ) ),
|
||||
new ClaimsPrincipal( new ClaimsIdentity( claims, "Auth" ) ),
|
||||
new AuthenticationProperties {
|
||||
AllowRefresh = true,
|
||||
IssuedUtc = DateTime.UtcNow,
|
||||
ExpiresUtc = DateTime.UtcNow.AddDays( 32 ),
|
||||
IsPersistent = true,
|
||||
ExpiresUtc = DateTime.UtcNow.AddYears(30), // Add 30 years with sliding on
|
||||
IsPersistent = request.EmailVerified, // Is set from the StayLoggedIn
|
||||
}
|
||||
);
|
||||
return test;
|
||||
|
||||
Reference in New Issue
Block a user