mirror of
https://github.com/Retrospring/retrospring.git
synced 2024-11-20 12:19:52 +01:00
Merge pull request #1410 from Retrospring/feature/load-async-pinned-answers
This commit is contained in:
commit
e351990475
1 changed files with 1 additions and 1 deletions
|
@ -8,7 +8,7 @@ class UserController < ApplicationController
|
|||
after_action :mark_notification_as_read, only: %i[show]
|
||||
|
||||
def show
|
||||
@pinned_answers = @user.answers.pinned.includes([{ user: :profile }, :question]).order(pinned_at: :desc).limit(10)
|
||||
@pinned_answers = @user.answers.pinned.includes([{ user: :profile }, :question]).order(pinned_at: :desc).limit(10).load_async
|
||||
paginate_answers { |args| @user.cursored_answers(**args) }
|
||||
|
||||
respond_to do |format|
|
||||
|
|
Loading…
Reference in a new issue