mirror of
https://github.com/wahyd4/gitlabhq.git
synced 2026-08-15 07:36:41 +10:00
Use >= instead of > in TrendingProjectsFinder
By using >= we can ensure we actually get all comments of the past month, instead of the comments of the past month minus the first day in the range.
This commit is contained in:
@@ -6,7 +6,7 @@ class TrendingProjectsFinder
|
||||
|
||||
# Determine trending projects based on comments count
|
||||
# for period of time - ex. month
|
||||
projects.joins(:notes).where('notes.created_at > ?', start_date).
|
||||
projects.joins(:notes).where('notes.created_at >= ?', start_date).
|
||||
group("projects.id").reorder("count(notes.id) DESC")
|
||||
end
|
||||
|
||||
|
||||
Reference in New Issue
Block a user