From 80351caf6dec0f1f2ebaccacd88d7175676e340f Mon Sep 17 00:00:00 2001 From: Gauvain Pocentek Date: Thu, 21 Sep 2017 21:58:55 +0200 Subject: Fix a couple listing calls to allow proper pagination Project.repository_tree and Project.repository_contributors return lists, so use http_list to allow users to use listing features such as `all=True`. Closes #314 --- gitlab/v4/objects.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'gitlab') diff --git a/gitlab/v4/objects.py b/gitlab/v4/objects.py index 0387815..9e02560 100644 --- a/gitlab/v4/objects.py +++ b/gitlab/v4/objects.py @@ -1815,8 +1815,8 @@ class Project(SaveMixin, ObjectDeleteMixin, RESTObject): query_data['path'] = path if ref: query_data['ref'] = ref - return self.manager.gitlab.http_get(gl_path, query_data=query_data, - **kwargs) + return self.manager.gitlab.http_list(gl_path, query_data=query_data, + **kwargs) @cli.register_custom_action('Project', ('sha', )) @exc.on_http_error(exc.GitlabGetError) @@ -1904,7 +1904,7 @@ class Project(SaveMixin, ObjectDeleteMixin, RESTObject): list: The contributors """ path = '/projects/%s/repository/contributors' % self.get_id() - return self.manager.gitlab.http_get(path, **kwargs) + return self.manager.gitlab.http_list(path, **kwargs) @cli.register_custom_action('Project', tuple(), ('sha', )) @exc.on_http_error(exc.GitlabListError) -- cgit v1.2.1