mirror of
https://github.com/discourse/discourse.git
synced 2025-06-01 02:34:28 +08:00
minor styling changes, kill n+1 query
This commit is contained in:
@ -53,7 +53,7 @@ class CategoryList
|
||||
.order('COALESCE(categories.topics_year, 0) DESC')
|
||||
|
||||
if latest_post_only?
|
||||
@categories = @categories.includes(:latest_post => :topic )
|
||||
@categories = @categories.includes(:latest_post => {:topic => :last_poster} )
|
||||
end
|
||||
|
||||
@categories = @categories.to_a
|
||||
|
Reference in New Issue
Block a user