Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRémy Coutable <remy@rymai.me>2017-01-10 16:43:06 +0300
committerRémy Coutable <remy@rymai.me>2017-01-12 00:52:30 +0300
commit83c1395af2e457a1de919a67ff7a2b21dceaeeef (patch)
tree96b5c831e33636ba0ce11ab34f5591eaf30e7fde /app/controllers/admin/groups_controller.rb
parentdafd5531ed793321eb8d886715654b4d572b2880 (diff)
Refactor authorized params in Admin::GroupsController
Signed-off-by: Rémy Coutable <remy@rymai.me>
Diffstat (limited to 'app/controllers/admin/groups_controller.rb')
-rw-r--r--app/controllers/admin/groups_controller.rb8
1 files changed, 6 insertions, 2 deletions
diff --git a/app/controllers/admin/groups_controller.rb b/app/controllers/admin/groups_controller.rb
index add1c819adf..b7722a1d15d 100644
--- a/app/controllers/admin/groups_controller.rb
+++ b/app/controllers/admin/groups_controller.rb
@@ -61,7 +61,11 @@ class Admin::GroupsController < Admin::ApplicationController
end
def group_params
- params.require(:group).permit(
+ params.require(:group).permit(group_params_ce)
+ end
+
+ def group_params_ce
+ [
:avatar,
:description,
:lfs_enabled,
@@ -69,6 +73,6 @@ class Admin::GroupsController < Admin::ApplicationController
:path,
:request_access_enabled,
:visibility_level
- )
+ ]
end
end