mirror of
https://github.com/Retrospring/retrospring.git
synced 2025-03-15 23:50:02 +01:00
Only show people that have asked at least 1 question (Discover)
This commit is contained in:
parent
7b30ee5bbb
commit
6c48e47f2c
1 changed files with 2 additions and 2 deletions
|
@ -6,7 +6,7 @@ class DiscoverController < ApplicationController
|
|||
|
||||
@popular_answers = Answer.where("created_at > ?", Time.now.ago(1.week)).order(:smile_count).reverse_order.limit(top_x)
|
||||
@popular_questions = Question.where("created_at > ?", Time.now.ago(1.week)).order(:answer_count).reverse_order.limit(top_x)
|
||||
@new_users = User.order(:id).reverse_order.limit(top_x)
|
||||
@new_users = User.where("asked_count > 0").order(:id).reverse_order.limit(top_x)
|
||||
|
||||
# .user = the user
|
||||
# .question_count = how many questions did the user ask
|
||||
|
|
Loading…
Reference in a new issue