public ActionResult Delete(int id, IFormCollection collection) { try { // TODO: Add delete logic here _context.Delete(id); return(RedirectToAction(nameof(Index))); } catch { return(View()); } }