C# VS更新后,SigninManager.SignOutAsync()在IIS Express中不工作

C# VS更新后,SigninManager.SignOutAsync()在IIS Express中不工作,c#,visual-studio,asp.net-core,iis-express,asp.net-core-identity,C#,Visual Studio,Asp.net Core,Iis Express,Asp.net Core Identity,我的ASP.Net核心MVC项目在过去两年左右一直运行良好。它基本上使用了从那时起由VisualStudio模板生成的登录/注销代码。我的注销代码如下所示: [HttpGet] public async Task<IActionResult> Logout() { await _signInManager.SignOutAsync(); _logger.LogInformation("User logged out."); return RedirectToA

我的ASP.Net核心MVC项目在过去两年左右一直运行良好。它基本上使用了从那时起由VisualStudio模板生成的登录/注销代码。我的注销代码如下所示:

[HttpGet]
public async Task<IActionResult> Logout()
{
    await _signInManager.SignOutAsync();
    _logger.LogInformation("User logged out.");
    return RedirectToAction(nameof(HomeController.Index), "Home");
}

任何帮助都将不胜感激!这完全让我出轨了,因为我经常登录和注销以测试不同的用户权限…

此外,使用Google Chrome开发工具中的“网络”选项卡将发布的工作版本与损坏的调试版本进行比较,请求的文件在这两个版本中看起来都是相同的,使用Google Chrome开发工具中的“网络”选项卡将发布的工作版本与损坏的调试版本进行比较,请求的文件在这两个版本中看起来完全相同。
// does not work
await HttpContext.SignOutAsync(IdentityConstants.ApplicationScheme);
await HttpContext.SignOutAsync(IdentityConstants.ExternalScheme, new AuthenticationProperties
{
    RedirectUri = "/Home/Index"
});