// GET: Cities/Edit/5 public async Task <IActionResult> Edit(int?id) { if (id == null) { return(NotFound()); } var city = _dbAccess.FindCity(id.Value); if (city == null) { return(NotFound()); } return(View(city)); }