public IHttpActionResult GetFavorite(int id) { try { SpecialistManager manager = new SpecialistManager(); List <Favorite> lista = manager.Favorite(id); GetFavorites temp; temp.favorites = lista; return(Ok(temp)); } catch (Exception e) { return(NotFound()); } }