Remove unnecessary eager loading (#6063)
Bullet doesn't seem to like this, and it makes sense because we don't want to load ALL reactions, just some of them. Co-authored-by: nspinazz89 <nspinazz89@gmail.com> Co-authored-by: Nick S <nspinazz89@gmail.com>
This commit is contained in:
parent
cc53b55a4a
commit
40bc7ecedd
1 changed files with 0 additions and 2 deletions
|
|
@ -6,7 +6,6 @@ class Internal::CommentsController < Internal::ApplicationController
|
|||
Comment.
|
||||
includes(:user).
|
||||
includes(:commentable).
|
||||
includes(:reactions).
|
||||
order("positive_reactions_count DESC").
|
||||
where("created_at > ?", params[:state].split("-").last.to_i.days.ago).
|
||||
page(params[:page] || 1).per(50)
|
||||
|
|
@ -14,7 +13,6 @@ class Internal::CommentsController < Internal::ApplicationController
|
|||
Comment.
|
||||
includes(:user).
|
||||
includes(:commentable).
|
||||
includes(:reactions).
|
||||
order("created_at DESC").
|
||||
page(params[:page] || 1).per(50)
|
||||
end
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue