mirror of
https://github.com/discourse/discourse.git
synced 2025-09-09 15:29:41 +08:00
FIX: Staff users are not affected by enable_group_directory
site setting.
This commit is contained in:
parent
6995382323
commit
d9d86577ff
3 changed files with 27 additions and 4 deletions
|
@ -37,7 +37,7 @@ class GroupsController < ApplicationController
|
|||
}
|
||||
|
||||
def index
|
||||
unless SiteSetting.enable_group_directory?
|
||||
unless SiteSetting.enable_group_directory? || current_user&.staff?
|
||||
raise Discourse::InvalidAccess.new(:enable_group_directory)
|
||||
end
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue