in tag view, do not use more-or-less random context for the form

See #1834 for a discussion
This commit is contained in:
Carsten Otto 2015-05-14 15:13:45 +02:00
parent 556c68c2e6
commit dd21e7466c

View file

@ -639,9 +639,6 @@ class TodosController < ApplicationController
# Set defaults for new_action
@initial_tags = @tag_name
unless @not_done_todos.empty?
@context = current_user.contexts.find(@not_done_todos.first.context_id)
end
# Set count badge to number of items with this tag
@not_done_todos.empty? ? @count = 0 : @count = @not_done_todos.size