summaryrefslogtreecommitdiff
path: root/app
diff options
context:
space:
mode:
authorKatarzyna Kobierska <kkobierska@gmail.com>2016-07-14 10:53:56 +0200
committerKatarzyna Kobierska <kkobierska@gmail.com>2016-07-14 10:56:44 +0200
commitef892bc2bfa29046dd58441d8d9afe8b3cde0007 (patch)
tree022e319d1f97bcb285376ccd655c87f399f79929 /app
parent7968484dfa363537e6e7822ca1ec100bcd0ec4f8 (diff)
downloadgitlab-ce-ef892bc2bfa29046dd58441d8d9afe8b3cde0007.tar.gz
When Issue author assign or mention himself Todos are created
Diffstat (limited to 'app')
-rw-r--r--app/services/todo_service.rb3
1 files changed, 1 insertions, 2 deletions
diff --git a/app/services/todo_service.rb b/app/services/todo_service.rb
index 6bb0a72d30e..6b48d68cccb 100644
--- a/app/services/todo_service.rb
+++ b/app/services/todo_service.rb
@@ -194,7 +194,7 @@ class TodoService
end
def create_assignment_todo(issuable, author)
- if issuable.assignee && issuable.assignee != author
+ if issuable.assignee
attributes = attributes_for_todo(issuable.project, issuable, author, Todo::ASSIGNED)
create_todos(issuable.assignee, attributes)
end
@@ -239,7 +239,6 @@ class TodoService
def filter_mentioned_users(project, target, author)
mentioned_users = target.mentioned_users(author)
mentioned_users = reject_users_without_access(mentioned_users, project, target)
- mentioned_users.delete(author)
mentioned_users.uniq
end