mirror of
https://github.com/discourse/discourse.git
synced 2025-05-22 22:37:02 +08:00
FEATURE: Add site setting to disable group directory.
This commit is contained in:
@ -11,6 +11,10 @@ class GroupsController < ApplicationController
|
||||
skip_before_filter :preload_json, :check_xhr, only: [:posts_feed, :mentions_feed]
|
||||
|
||||
def index
|
||||
unless SiteSetting.enable_group_directory?
|
||||
raise Discourse::InvalidAccess.new(:enable_group_directory)
|
||||
end
|
||||
|
||||
page_size = 30
|
||||
page = params[:page]&.to_i || 0
|
||||
|
||||
|
Reference in New Issue
Block a user