diff options
author | Patrick Derichs <pderichs@gitlab.com> | 2019-08-09 14:54:57 +0200 |
---|---|---|
committer | Patrick Derichs <pderichs@gitlab.com> | 2019-08-28 15:04:23 +0200 |
commit | c9b4dc677abdebc02ecac4dca65a759d3f07b2a0 (patch) | |
tree | bc19401d0e29a912d6db7d13cc4fea71d68beda2 /lib/api/notes.rb | |
parent | 20920f8074a45c0e2c3bbeab9be44e7b6d1dd398 (diff) | |
download | gitlab-ce-c9b4dc677abdebc02ecac4dca65a759d3f07b2a0.tar.gz |
Filter out old system notes for epics
Diffstat (limited to 'lib/api/notes.rb')
-rw-r--r-- | lib/api/notes.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/api/notes.rb b/lib/api/notes.rb index 84563d66ee8..16fca9acccb 100644 --- a/lib/api/notes.rb +++ b/lib/api/notes.rb @@ -42,7 +42,7 @@ module API # array returned, but this is really a edge-case. notes = paginate(raw_notes) notes = prepare_notes_for_rendering(notes) - notes = notes.reject { |n| n.cross_reference_not_visible_for?(current_user) } + notes = notes.select { |note| note.visible_for?(current_user) } present notes, with: Entities::Note end # rubocop: enable CodeReuse/ActiveRecord |