Skip to content

Commit

Permalink
query revised (#3184)
Browse files Browse the repository at this point in the history
  • Loading branch information
grvsachdeva authored and jywarren committed Aug 2, 2018
1 parent 0e96e13 commit 062ff10
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion app/controllers/home_controller.rb
Original file line number Diff line number Diff line change
Expand Up @@ -127,7 +127,7 @@ def activity
revisions = revisions.to_a # ensure it can be serialized for caching
wikis += revisions
wikis = wikis.sort_by(&:created_at).reverse
comments = Comment.joins(:node, :drupal_user)
comments = Comment.where(status: 1).joins(:node, :drupal_user)
.order('timestamp DESC')
.where('timestamp - node.created > ?', 86_400) # don't report edits within 1 day of page creation
.where('node.status = ?', 1)
Expand Down

0 comments on commit 062ff10

Please sign in to comment.