diff options
| author | Gauvain Pocentek <gauvain@pocentek.net> | 2017-09-21 21:58:55 +0200 |
|---|---|---|
| committer | Gauvain Pocentek <gauvain@pocentek.net> | 2017-09-21 21:58:55 +0200 |
| commit | 80351caf6dec0f1f2ebaccacd88d7175676e340f (patch) | |
| tree | 2bc75619dfe66addf795040c6cd09e1a8e015ea2 | |
| parent | 7d6f3d0cd5890c8a71704419e78178ca887357fe (diff) | |
| download | gitlab-80351caf6dec0f1f2ebaccacd88d7175676e340f.tar.gz | |
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
| -rw-r--r-- | gitlab/v4/objects.py | 6 |
1 files changed, 3 insertions, 3 deletions
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) |
