diff options
author | Eugen Rochko <eugen@zeonfederated.com> | 2016-11-22 23:18:54 +0100 |
---|---|---|
committer | Eugen Rochko <eugen@zeonfederated.com> | 2016-11-22 23:18:54 +0100 |
commit | 5c78547198de20e7f367adb142acc82cd80b4899 (patch) | |
tree | 18df6af1dc5042e44c67156586822bd8798f6c84 /app/models/feed.rb | |
parent | fc90d38893ae81b83884c3f5c85d05d564f1de33 (diff) |
More query optimizations
Diffstat (limited to 'app/models/feed.rb')
-rw-r--r-- | app/models/feed.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/app/models/feed.rb b/app/models/feed.rb index e7f2ab3a5..6337726be 100644 --- a/app/models/feed.rb +++ b/app/models/feed.rb @@ -16,7 +16,7 @@ class Feed RegenerationWorker.perform_async(@account.id, @type) @statuses = Status.send("as_#{@type}_timeline", @account).paginate_by_max_id(limit, nil, nil) else - status_map = Status.where(id: unhydrated).with_includes.with_counters.map { |status| [status.id, status] }.to_h + status_map = Status.where(id: unhydrated).with_includes.map { |status| [status.id, status] }.to_h @statuses = unhydrated.map { |id| status_map[id] }.compact end |