diff options
author | Artem Sidorenko <artem.sidorenko@telekom.de> | 2015-08-12 08:13:20 +0200 |
---|---|---|
committer | Artem Sidorenko <artem.sidorenko@telekom.de> | 2015-08-20 11:28:27 +0200 |
commit | 55dca86b983496a26a3913aead77439edf96afe9 (patch) | |
tree | c02b8dfe8aba50265f59ba0170eb09b9fc2f9e19 /app/controllers/admin/application_settings_controller.rb | |
parent | 55fc58bda4a5592f2f8deaecec9526fbe4eecd6f (diff) | |
download | gitlab-ce-55dca86b983496a26a3913aead77439edf96afe9.tar.gz |
Import sources: settings in the admin interface
Diffstat (limited to 'app/controllers/admin/application_settings_controller.rb')
-rw-r--r-- | app/controllers/admin/application_settings_controller.rb | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/app/controllers/admin/application_settings_controller.rb b/app/controllers/admin/application_settings_controller.rb index c7c643db401..f38e07af84b 100644 --- a/app/controllers/admin/application_settings_controller.rb +++ b/app/controllers/admin/application_settings_controller.rb @@ -29,6 +29,15 @@ class Admin::ApplicationSettingsController < Admin::ApplicationController end end + import_sources = params[:application_setting][:import_sources] + if import_sources.nil? + params[:application_setting][:import_sources] = [] + else + import_sources.map! do |source| + source.to_str + end + end + params.require(:application_setting).permit( :default_projects_limit, :default_branch_protection, @@ -47,6 +56,7 @@ class Admin::ApplicationSettingsController < Admin::ApplicationController :version_check_enabled, :user_oauth_applications, restricted_visibility_levels: [], + import_sources: [] ) end end |