UserManager OWIN event or delegate expected

0

Cześć.

Pisząc swój projekt otrzymałem pewien błąd:

Error 1 'Microsoft.Owin.IOwinContext' does not contain a definition for 'GetUserManager' and no extension method 'GetUserManager' accepting a first argument of type 'Microsoft.Owin.IOwinContext' could be found (are you missing a using directive or an assembly reference?) C:\Users\Odyn\Documents\MyProject\Controllers\AccountController.cs 38 69

W Account Controlerze nagle podkresla mi:

 
 public ApplicationUserManager UserManager
        {
            get
            {
                return _userManager ?? HttpContext.GetOwinContext().GetUserManager<ApplicationUserManager>();
            }
            private set
            {
                _userManager = value;
            }
        }

Oraz w IdentityCOnfig.cs

 var manager = new ApplicationUserManager(new UserStore<ApplicationUser>(context.Get<ApplicationDbContext>()));
 

Co robie zle? Czego mi brakuje? Przez ten błąd projekt przestał się buildować :(

0

Masz using Microsoft.AspNet.Identity.Owin;?

0

Mam ale podkreśla, że jest nie używany... :(

user image

Tak to wygląda:

user image

1 użytkowników online, w tym zalogowanych: 0, gości: 1