Commit 3c2139ed authored by Dmitriy Zaporozhets's avatar Dmitriy Zaporozhets

Fix trending projects ordering

parent 23179770
......@@ -8,7 +8,7 @@ class TrendingProjectsFinder
# for period of time - ex. month
projects.joins(:notes).where('notes.created_at > ?', start_date).
select("projects.*, count(notes.id) as ncount").
group("projects.id").order("ncount DESC")
group("projects.id").reorder("ncount DESC")
end
private
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment