mirror of
https://github.com/discourse/discourse.git
synced 2025-02-25 18:55:32 -06:00
FIX: Do not show unconfirmed users in search results
This commit is contained in:
@@ -263,7 +263,7 @@ class Search
|
||||
|
||||
def user_search
|
||||
users = User.includes(:user_search_data)
|
||||
.where("user_search_data.search_data @@ #{ts_query("simple")}")
|
||||
.where("active = true AND user_search_data.search_data @@ #{ts_query("simple")}")
|
||||
.order("CASE WHEN username_lower = '#{@original_term.downcase}' THEN 0 ELSE 1 END")
|
||||
.order("last_posted_at DESC")
|
||||
.limit(@limit)
|
||||
|
||||
Reference in New Issue
Block a user