Fix status_reference indexing
This commit is contained in:
parent
3a5b8819d6
commit
020e50d0c5
1 changed files with 1 additions and 1 deletions
|
@ -54,7 +54,7 @@ class StatusesIndex < Chewy::Index
|
|||
end
|
||||
|
||||
crutch :status_references do |collection|
|
||||
data = ::StatusReference.joins(:status).where(target_status_id: collection.map(&:id), status: { account: Account.local }).pluck(:status_id, :account_id)
|
||||
data = ::StatusReference.joins(:status).where(target_status_id: collection.map(&:id), status: { account: Account.local }).pluck(:target_status_id, :account_id)
|
||||
data.each.with_object({}) { |(id, name), result| (result[id] ||= []).push(name) }
|
||||
end
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue