ASP.NET MVC 5 Identity userManager.IsInRole

瘦欲@ 提交于 2019-12-01 08:41:51

So I will answer this myself to save anyone the hours of pain I suffered because of this.

The reason for this occurring was that I had lazy loading disabled, I have enabled this to be on in my Migrations project like so.

protected override void Seed(BlogContext blogContext)
    {
        AutomaticMigrationsEnabled = true;
        blogContext.Configuration.LazyLoadingEnabled = true;
        //Add seed classes here!    
    }
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!