public ActionResult <IEnumerable <Car> > GetAll() { try { return(Ok(_cs.GetAll())); } catch (System.Exception) { throw; } }
public ActionResult <IEnumerable <Car> > GetAll() { try { return(Ok(_cs.GetAll())); } catch (System.Exception err) { return(BadRequest(err.Message)); } }