summaryrefslogtreecommitdiff
path: root/app/helpers/todos_helper.rb
diff options
context:
space:
mode:
authorDouglas Barbosa Alexandre <dbalexandre@gmail.com>2016-06-14 23:09:48 -0300
committerDouglas Barbosa Alexandre <dbalexandre@gmail.com>2016-06-17 16:17:43 -0300
commit2878c990052f78fae3cde21a1d2cd90dd5a85461 (patch)
tree6b026bd7ec4c80c2f46deef6e2009496a024b200 /app/helpers/todos_helper.rb
parentbb4a1ef6c1ed4d367e6126ad64033e0286da6f15 (diff)
downloadgitlab-ce-2878c990052f78fae3cde21a1d2cd90dd5a85461.tar.gz
Ensure Todos counters doesn't count Todos for projects pending delete
Diffstat (limited to 'app/helpers/todos_helper.rb')
-rw-r--r--app/helpers/todos_helper.rb4
1 files changed, 2 insertions, 2 deletions
diff --git a/app/helpers/todos_helper.rb b/app/helpers/todos_helper.rb
index c7aeed4b9fc..e1d8517f712 100644
--- a/app/helpers/todos_helper.rb
+++ b/app/helpers/todos_helper.rb
@@ -1,10 +1,10 @@
module TodosHelper
def todos_pending_count
- current_user.todos_pending_count
+ TodosFinder.new(current_user, state: :pending).execute.count
end
def todos_done_count
- current_user.todos_done_count
+ TodosFinder.new(current_user, state: :done).execute.count
end
def todo_action_name(todo)