public ActionResult DeleteExpire(int id) { var modelFromRepo = _repository.GetExpireById(id); if (modelFromRepo == null) { return(NotFound()); } _repository.DeleteExpire(modelFromRepo); _repository.SaveChanges(); return(NoContent()); }