public async Task <ActionResult> Delete(string id) { _EducationLevel.Remove(id); // it won't be null // var testEducationLevel = await _EducationLevel.GetById(id); // If everything is ok then: await _uow.Commit(); // not it must by null // testEducationLevel = await _EducationLevel.GetById(id); return(RedirectToAction("Index")); }