summaryrefslogtreecommitdiff
path: root/app/models/note.rb
diff options
context:
space:
mode:
Diffstat (limited to 'app/models/note.rb')
-rw-r--r--app/models/note.rb10
1 files changed, 5 insertions, 5 deletions
diff --git a/app/models/note.rb b/app/models/note.rb
index c6406f644e0..d6d5396afa5 100644
--- a/app/models/note.rb
+++ b/app/models/note.rb
@@ -105,14 +105,14 @@ class Note < ActiveRecord::Base
def grouped_diff_discussions
active_notes = diff_notes.fresh.select(&:active?)
- Discussion.for_diff_notes(active_notes)
- .map { |d| [d.line_code, d] }.to_h
+ Discussion.for_diff_notes(active_notes).
+ map { |d| [d.line_code, d] }.to_h
end
def count_for_collection(ids, type)
- user.select('noteable_id', 'COUNT(*) as count')
- .group(:noteable_id)
- .where(noteable_type: type, noteable_id: ids)
+ user.select('noteable_id', 'COUNT(*) as count').
+ group(:noteable_id).
+ where(noteable_type: type, noteable_id: ids)
end
end