Skip to content

Commit

Permalink
Cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
Isaac Wilson committed Sep 6, 2022
1 parent 8fb56b8 commit c8a5052
Showing 1 changed file with 0 additions and 3 deletions.
3 changes: 0 additions & 3 deletions server/events/vcs/gitlab_client.go
Original file line number Diff line number Diff line change
Expand Up @@ -224,16 +224,13 @@ func (g *GitlabClient) PullIsMergeable(repo models.Repo, pull models.PullRequest
isPipelineSkipped := false
if mr.HeadPipeline != nil {
isPipelineSkipped = mr.HeadPipeline.Status == "skipped"

// Edge case for when second branch and accompanying MR is opened from same commit
} else {
pipelines, _, err := g.Client.Pipelines.ListProjectPipelines(repo.FullName, &gitlab.ListProjectPipelinesOptions{
SHA: &mr.SHA,
})
if err != nil {
return false, err
}
// Should we only look at first pipeline?
for _, p := range pipelines {
if p.Status == "skipped" {
isPipelineSkipped = true
Expand Down

0 comments on commit c8a5052

Please sign in to comment.