public IHttpActionResult RestaurantById(int id) { var res = _repo.GetById(id); if (res != null) { return(Ok <Restaurant>(res)); } else { return(NotFound()); } }