MVC5, WebAPI2 and AutoFac not working. All Nuget packages updated

asp.net Web-ApiAutofacasp.net Mvc-5

asp.net Web-Api Problem Overview


I've updated all of the nuget packages in my project, as well as the AutoFac MVC5 Integration package (removed MVC4 one) and still no dice.

>Inheritance security rules violated while overriding member: 'Autofac.Integration.WebApi.AutofacWebApiDependencyResolver.BeginScope()'. Security accessibility of the overriding method must match the security accessibility of the method being overriden.

asp.net Web-Api Solutions


Solution 1 - asp.net Web-Api

The package you need can be found by searching for "autofac webapi2" on Nuget.
It is called Autofac ASP.NET WebApi 2 Integration.

Attributions

All content for this solution is sourced from the original question on Stackoverflow.

The content on this page is licensed under the Attribution-ShareAlike 4.0 International (CC BY-SA 4.0) license.

Content TypeOriginal AuthorOriginal Content on Stackoverflow
QuestionShaneView Question on Stackoverflow
Solution 1 - asp.net Web-ApiAlex Meyer-GleavesView Answer on Stackoverflow