Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Fix stats

  • Loading branch information...
commit 3508fe82c426235f980505474f50c787551339d4 1 parent f279fb9
Benoît Sibaud authored nono committed
Showing with 1 addition and 1 deletion.
  1. +1 −1  app/models/statistics/moderation.rb
View
2  app/models/statistics/moderation.rb
@@ -48,7 +48,7 @@ def top_am
end
def nb_moderations_x_days(user_id,nbdays)
- count "SELECT COUNT(*) AS cnt FROM nodes JOIN news ON nodes.content_id = news.id AND nodes.content_type='News' WHERE nodes.created_at >= '#{nbdays.days.ago.to_s :db}' AND user_id=#{user_id}"
+ count "SELECT COUNT(*) AS cnt FROM nodes JOIN news ON nodes.content_id = news.id AND nodes.content_type='News' WHERE nodes.created_at >= '#{nbdays.days.ago.to_s :db}' AND moderation_id=#{user_id}"
end
def nb_editions_x_days(user_id,nbdays)
Please sign in to comment.
Something went wrong with that request. Please try again.