diff options
| author | Nejc Habjan <hab.nejc@gmail.com> | 2021-05-02 19:48:51 +0200 |
|---|---|---|
| committer | Nejc Habjan <hab.nejc@gmail.com> | 2021-05-02 19:48:51 +0200 |
| commit | 9fed06116bfe5df79e6ac5be86ae61017f9a2f57 (patch) | |
| tree | 63f329a4f72cf9ace085a8b585324b2fbb9550bb /gitlab/v4/objects | |
| parent | b563cdc1a6cd585647fc53722081dceb6f7b4466 (diff) | |
| download | gitlab-9fed06116bfe5df79e6ac5be86ae61017f9a2f57.tar.gz | |
fix(objects): return server data in cancel/retry methods
Diffstat (limited to 'gitlab/v4/objects')
| -rw-r--r-- | gitlab/v4/objects/jobs.py | 4 | ||||
| -rw-r--r-- | gitlab/v4/objects/pipelines.py | 4 |
2 files changed, 4 insertions, 4 deletions
diff --git a/gitlab/v4/objects/jobs.py b/gitlab/v4/objects/jobs.py index e6e04e1..6274f16 100644 --- a/gitlab/v4/objects/jobs.py +++ b/gitlab/v4/objects/jobs.py @@ -24,7 +24,7 @@ class ProjectJob(RefreshMixin, RESTObject): GitlabJobCancelError: If the job could not be canceled """ path = "%s/%s/cancel" % (self.manager.path, self.get_id()) - self.manager.gitlab.http_post(path) + return self.manager.gitlab.http_post(path) @cli.register_custom_action("ProjectJob") @exc.on_http_error(exc.GitlabJobRetryError) @@ -39,7 +39,7 @@ class ProjectJob(RefreshMixin, RESTObject): GitlabJobRetryError: If the job could not be retried """ path = "%s/%s/retry" % (self.manager.path, self.get_id()) - self.manager.gitlab.http_post(path) + return self.manager.gitlab.http_post(path) @cli.register_custom_action("ProjectJob") @exc.on_http_error(exc.GitlabJobPlayError) diff --git a/gitlab/v4/objects/pipelines.py b/gitlab/v4/objects/pipelines.py index 724c5e8..95063d4 100644 --- a/gitlab/v4/objects/pipelines.py +++ b/gitlab/v4/objects/pipelines.py @@ -50,7 +50,7 @@ class ProjectPipeline(RefreshMixin, ObjectDeleteMixin, RESTObject): GitlabPipelineCancelError: If the request failed """ path = "%s/%s/cancel" % (self.manager.path, self.get_id()) - self.manager.gitlab.http_post(path) + return self.manager.gitlab.http_post(path) @cli.register_custom_action("ProjectPipeline") @exc.on_http_error(exc.GitlabPipelineRetryError) @@ -65,7 +65,7 @@ class ProjectPipeline(RefreshMixin, ObjectDeleteMixin, RESTObject): GitlabPipelineRetryError: If the request failed """ path = "%s/%s/retry" % (self.manager.path, self.get_id()) - self.manager.gitlab.http_post(path) + return self.manager.gitlab.http_post(path) class ProjectPipelineManager(RetrieveMixin, CreateMixin, DeleteMixin, RESTManager): |
