public ActionResult DeleteColor(ColorModel model) { try { var resp = model.Delete(); if (resp.WasSuccessful) { TempData["Messages"] = "Color Deleted!"; } else { TempData["Errors"] = resp.Message; } } catch (Exception ex) { TempData["Errors"] = ex.Message; } return(RedirectToAction("Colors")); }