mirror of
https://github.com/discourse/discourse.git
synced 2026-09-05 04:40:41 -05:00
FIX: Protection against dangling category group records
This commit is contained in:
@@ -310,7 +310,9 @@ SQL
|
||||
def permissions_params
|
||||
hash = {}
|
||||
category_groups.includes(:group).each do |category_group|
|
||||
hash[category_group.group_name] = category_group.permission_type
|
||||
if category_group.group.present?
|
||||
hash[category_group.group_name] = category_group.permission_type
|
||||
end
|
||||
end
|
||||
hash
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user