How to add MVC 5 authentication to Unity IoC?

前端 未结 2 757
执笔经年
执笔经年 2020-12-14 17:46

I\'m currently working on implementing the new ASP.NET MVC 5 out-of-the box authentication into my application. However when using Unity as my IoC, I cannot use any portion

2条回答
  •  情书的邮戳
    2020-12-14 18:12

    I agree with Wiktor.

    You could register the parameterless constructor with Unity though and stop it taking the longer parameter by doing this:

    container.RegisterType(new InjectionConstructor());
    

提交回复
热议问题