diff options
author | Andreas Brandl <abrandl@gitlab.com> | 2018-02-12 18:20:42 +0100 |
---|---|---|
committer | Andreas Brandl <abrandl@gitlab.com> | 2018-02-13 18:04:52 +0100 |
commit | c11e80699783ca2915a59c69f234d8d3aff256d8 (patch) | |
tree | ea9ba2121540a05f9c3b4f646407534d73dd1a44 /app/finders | |
parent | 95738d4b75a132210eb1d7c9ac7d35e4ea4a86bd (diff) | |
download | gitlab-ce-c11e80699783ca2915a59c69f234d8d3aff256d8.tar.gz |
Always eagerly load a note's author.
Diffstat (limited to 'app/finders')
-rw-r--r-- | app/finders/notes_finder.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/app/finders/notes_finder.rb b/app/finders/notes_finder.rb index 12157818bcd..33ee1e975b9 100644 --- a/app/finders/notes_finder.rb +++ b/app/finders/notes_finder.rb @@ -57,7 +57,7 @@ class NotesFinder types = %w(commit issue merge_request snippet) note_relations = types.map { |t| notes_for_type(t) } note_relations.map! { |notes| search(notes) } - UnionFinder.new.find_union(note_relations, Note) + UnionFinder.new.find_union(note_relations, Note.includes(:author)) end def noteables_for_type(noteable_type) |