// GET: CUsers/Details/5 public async Task <IActionResult> Details(int?id) { if (id == null) { return(NotFound()); } var users = await _userRep.GetUserById(id.Value); if (users == null) { return(NotFound()); } return(View(users)); }