提交 a563f331 编写于 作者: L Lin Jen-Shin

Join on association

上级 66c8c3d4
......@@ -431,7 +431,7 @@ class Project < ActiveRecord::Base
# ref can't be HEAD, can only be branch/tag name or SHA
def latest_successful_builds_for(ref = default_branch)
Ci::Build.joins(:pipeline).merge(pipelines.latest_successful_for(ref)).
builds.joins(:pipeline).merge(pipelines.latest_successful_for(ref)).
latest_successful_with_artifacts
end
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册