Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
佳 邓
Gitlab4j Api
Commits
4c014541
Commit
4c014541
authored
Apr 26, 2018
by
Greg Messner
Browse files
Fixed createPipeline, was looking for OK instead of CREATED.
parent
0f63ef12
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/main/java/org/gitlab4j/api/PipelineApi.java
View file @
4c014541
...
...
@@ -192,8 +192,7 @@ public class PipelineApi extends AbstractApi implements Constants {
*/
public
Pipeline
createPipeline
(
int
projectId
,
String
ref
)
throws
GitLabApiException
{
GitLabApiForm
formData
=
new
GitLabApiForm
().
withParam
(
"ref"
,
ref
);
Response
response
=
post
(
Response
.
Status
.
OK
,
formData
.
asMap
(),
"projects"
,
projectId
,
"pipelines"
);
Response
response
=
post
(
Response
.
Status
.
CREATED
,
formData
.
asMap
(),
"projects"
,
projectId
,
"pipelines"
);
return
(
response
.
readEntity
(
Pipeline
.
class
));
}
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment