提交 16c8b910 编写于 作者: M micael.bergeron

revert the `#all_pipelines` method to use the pluck

the `ci_pipelines.sha` column is not the same type than the
`merge_request_diff_commits.sha` column (varchar, bytea)
上级 cb6f51ec
...@@ -921,9 +921,8 @@ class MergeRequest < ActiveRecord::Base ...@@ -921,9 +921,8 @@ class MergeRequest < ActiveRecord::Base
def all_pipelines def all_pipelines
return Ci::Pipeline.none unless source_project return Ci::Pipeline.none unless source_project
commit_shas = all_commits.unscope(:limit).select(:sha)
@all_pipelines ||= source_project.pipelines @all_pipelines ||= source_project.pipelines
.where(sha: commit_shas, ref: source_branch) .where(sha: all_commit_shas, ref: source_branch)
.order(id: :desc) .order(id: :desc)
end end
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册