public async Task<ActionResult> Edit(EditModel post)
 {
     EditModel editModel = post;
     User user = await UserManager.FindByIdAsync(editModel.User.Id);
     if (user != null)
     {
         users.Edit(editModel.User);      
         IdentityResult validPass = null;
         if (editModel.Password != string.Empty && editModel.Password != null)
         {
             validPass
                 = await UserManager.PasswordValidator.ValidateAsync(editModel.Password);
             if (validPass.Succeeded)
             {
                 user.PasswordHash =
                     UserManager.PasswordHasher.HashPassword(editModel.Password);
             }
             else
             {
                 AddErrorsFromResult(validPass);
             }
         }
         if ((validPass == null) || (editModel.Password != string.Empty && validPass.Succeeded))
         {
             return RedirectToAction("Index"); 
         }
     }
     else
     {
         ModelState.AddModelError("", "User Not Found");
     }
     return View(user);
                
 }
 public ActionResult Edit(int UserID)
 {
     EditModel model = new EditModel();
     model.User = UserManager.FindById(UserID); 
     return View(model);
 }