summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRémy Coutable <remy@rymai.me>2017-01-10 15:57:09 +0100
committerRémy Coutable <remy@rymai.me>2017-01-12 17:33:21 -0500
commit9e0d3906b931eb0f81c9cd9864891ca26cbefd44 (patch)
tree0eb3c275c0af3477af72dba75eb860b6ecd3ad64
parent6195ab754dcaac0930f01dae86d39adf9ac0fce9 (diff)
downloadgitlab-ce-9e0d3906b931eb0f81c9cd9864891ca26cbefd44.tar.gz
Refactor authorized params in GroupsController
Signed-off-by: Rémy Coutable <remy@rymai.me>
-rw-r--r--app/controllers/groups_controller.rb8
1 files changed, 6 insertions, 2 deletions
diff --git a/app/controllers/groups_controller.rb b/app/controllers/groups_controller.rb
index b61f4e9a2db..f81237db991 100644
--- a/app/controllers/groups_controller.rb
+++ b/app/controllers/groups_controller.rb
@@ -125,7 +125,11 @@ class GroupsController < Groups::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,
@@ -135,7 +139,7 @@ class GroupsController < Groups::ApplicationController
:request_access_enabled,
:share_with_group_lock,
:visibility_level
- )
+ ]
end
def load_events