public IActionResult Delete(int id) { if (ModelState.IsValid) { PersonData.DeletePerson(id); return(RedirectToAction("List")); } return(View()); }