You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Nov 20, 2018. It is now read-only.
The IHttpContextAccessor allows access to the current executing HttpContext and seems to be a core component of ASP.NET. Still however, the IHttpContextAccessor is not registered by default by ASP.NET while it IMO definitely should.
The whole idea behind the new configuration model in ASP.NET is that everything is registered for you magically behind the covers, but even if you call AddMvc or even AddMvcCore the IHttpContextAccessor isn't registered, while there are many integration scenarios that require its availability. This means that 3rd parties (or possibly even future framework components) always need to check its availability and throw an exception when it's not registered and application developers always need to register it manually.