fixed anonymous questions being shown

This commit is contained in:
nilsding 2014-12-19 23:12:19 +01:00
parent bdff6f4110
commit aa3f118332
1 changed files with 1 additions and 1 deletions

View File

@ -40,6 +40,6 @@ class UserController < ApplicationController
def questions
@title = 'Questions'
@user = User.where('LOWER(screen_name) = ?', params[:username].downcase).first
@questions = @user.questions.reverse_order.paginate(page: params[:page])
@questions = @user.questions.where(author_is_anonymous: false).reverse_order.paginate(page: params[:page])
end
end