AspNetCore MVC - ControllerBase.Challenge 问题

AspNetCore MVC - ControllerBase.Challenge Issue

尝试在我的 mvc 项目中使用 Challenge(AuthenticationProperties, String[])

 [Authorize]
 public IActionResult SignIn()
 {
     return Challenge(new AuthenticationProperties { RedirectUri = "/" }, OpenIdConnectDefaults.AuthenticationScheme);
 }

但是出现以下错误

cannot convert from Microsoft.AspNetCore.Http.Authentication.AuthenticationProperties to string

我是不是做错了什么?

已更新

找到问题

这是对AuthenticationProperties

的引用

这来自 Microsoft.AspNetCore.AuthenticationMicrosoft.AspNetCore.Http.Authentication

它指向 Microsoft.AspNetCore.Http.Authentication 导致了问题