Skip to content

A platform for community discussion. Free, open, simple.

FIX: Correct ordering for post_edits report, and remove query limit

David Taylor961213ba52eb
diff --git a/app/models/reports/post_edits.rb b/app/models/reports/post_edits.rb
index 3736788b1b1..90925204301 100644
--- a/app/models/reports/post_edits.rb
+++ b/app/models/reports/post_edits.rb
@@ -73,6 +73,7 @@ Report.add_report('post_edits') do |report|
ON editor.id = pr.user_id
/*join*/
/*where*/
+ ORDER BY pr.created_at ASC
/*limit*/
SQL
@@ -88,7 +89,6 @@ Report.add_report('post_edits') do |report|
builder.where("editor.id > 0 AND editor.id != author.id")
builder.where("pr.created_at >= :start_date", start_date: report.start_date)
builder.where("pr.created_at <= :end_date", end_date: report.end_date)
- builder.limit(report.limit || 20)
result = builder.query