summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--app/models/note.rb2
-rw-r--r--app/services/todo_service.rb2
2 files changed, 2 insertions, 2 deletions
diff --git a/app/models/note.rb b/app/models/note.rb
index 9191cae6391..3918bbee194 100644
--- a/app/models/note.rb
+++ b/app/models/note.rb
@@ -229,7 +229,7 @@ class Note < ActiveRecord::Base
!for_personal_snippet?
end
- def for_issuable_with_ability?
+ def for_issuable?
for_issue? || for_merge_request?
end
diff --git a/app/services/todo_service.rb b/app/services/todo_service.rb
index 4a7e89a63c7..46f12086555 100644
--- a/app/services/todo_service.rb
+++ b/app/services/todo_service.rb
@@ -321,7 +321,7 @@ class TodoService
end
def reject_users_without_access(users, parent, target)
- if target.is_a?(Note) && target.for_issuable_with_ability?
+ if target.is_a?(Note) && target.for_issuable?
target = target.noteable
end