mirror of
https://github.com/discourse/discourse.git
synced 2025-09-04 08:47:37 +08:00
correct search in topic list
This commit is contained in:
parent
6c29908ba2
commit
de5418a905
1 changed files with 1 additions and 1 deletions
|
@ -602,7 +602,7 @@ class TopicQuery
|
||||||
end
|
end
|
||||||
|
|
||||||
if search = options[:search]
|
if search = options[:search]
|
||||||
result = result.where("topics.id in (select pp.topic_id from post_search_data pd join posts pp on pp.id = pd.post_id where pd.search_data @@ #{Search.ts_query(search.to_s)})")
|
result = result.where("topics.id in (select pp.topic_id from post_search_data pd join posts pp on pp.id = pd.post_id where pd.search_data @@ #{Search.ts_query(term: search.to_s)})")
|
||||||
end
|
end
|
||||||
|
|
||||||
# NOTE protect against SYM attack can be removed with Ruby 2.2
|
# NOTE protect against SYM attack can be removed with Ruby 2.2
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue