diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2019-10-28 12:06:04 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2019-10-28 12:06:04 +0300 |
commit | 29eea410c440212730a33ddf610483fe095c8670 (patch) | |
tree | b3071ada8f9524f99bf8479006553b8146365792 /app/finders/todos_finder.rb | |
parent | 1a3d7b9fcda9e4eecd22b84f4254efc07344b284 (diff) |
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'app/finders/todos_finder.rb')
-rw-r--r-- | app/finders/todos_finder.rb | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/app/finders/todos_finder.rb b/app/finders/todos_finder.rb index 2b46e51290f..82acb5e9d45 100644 --- a/app/finders/todos_finder.rb +++ b/app/finders/todos_finder.rb @@ -188,11 +188,9 @@ class TodosFinder end def by_state(items) - if params[:state].to_s == 'done' - items.done - else - items.pending - end + return items.pending if params[:state].blank? + + items.with_states(params[:state]) end def by_type(items) |