Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorShinya Maeda <gitlab.shinyamaeda@gmail.com>2017-02-28 20:34:48 +0300
committerShinya Maeda <gitlab.shinyamaeda@gmail.com>2017-05-02 20:11:50 +0300
commitdf834306c1794ed72d6d655c7941dee28f7e85c7 (patch)
tree8bc6c2c173c7cbc803ad4036f7a43d4442cef109 /app/finders
parent994e49b3fbc261f8e59429c1681d83c81ba25df3 (diff)
Add specs. Plus, minor fixes.
Diffstat (limited to 'app/finders')
-rw-r--r--app/finders/pipelines_finder.rb8
1 files changed, 6 insertions, 2 deletions
diff --git a/app/finders/pipelines_finder.rb b/app/finders/pipelines_finder.rb
index c2e247a7ded..ff16d7305ad 100644
--- a/app/finders/pipelines_finder.rb
+++ b/app/finders/pipelines_finder.rb
@@ -88,8 +88,12 @@ class PipelinesFinder
end
def by_yaml_errors(items)
- if params[:yaml_errors].present? && params[:yaml_errors]
- items.where("yaml_errors IS NOT NULL")
+ if params[:yaml_errors].present?
+ if params[:yaml_errors]
+ items.where("yaml_errors IS NOT NULL")
+ else
+ items.where("yaml_errors IS NULL")
+ end
else
items
end