mirror of
https://github.com/discourse/discourse.git
synced 2025-05-31 03:32:17 +08:00
UX: Exclude child catgegories of muted category in similar to search (#19414)
Follow-up to 207b764ea37f13469db1117c5c1102ace05fd2f9
This commit is contained in:

committed by
GitHub

parent
c9197cf9d8
commit
332ac0f299
@ -642,7 +642,7 @@ class Topic < ActiveRecord::Base
|
||||
excluded_category_ids_sql = <<~SQL
|
||||
#{excluded_category_ids_sql}
|
||||
UNION
|
||||
#{CategoryUser.where(notification_level: CategoryUser.notification_levels[:muted], user: user).select(:category_id).to_sql}
|
||||
#{CategoryUser.muted_category_ids_query(user, include_direct: true).select("categories.id").to_sql}
|
||||
SQL
|
||||
end
|
||||
|
||||
|
Reference in New Issue
Block a user