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:
authorDmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>2018-04-13 18:54:08 +0300
committerDmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>2018-04-13 18:54:08 +0300
commit6106cad9559633cf69876ef5185b361df2a30123 (patch)
treecb75c262bcf83c3402f376da9f1d80247f4cada3 /app/helpers/application_settings_helper.rb
parentbcf7a7e76cc8aa4216f1df88be47172b9880ba24 (diff)
Don't reset application settings oauth providers by mistake
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
Diffstat (limited to 'app/helpers/application_settings_helper.rb')
-rw-r--r--app/helpers/application_settings_helper.rb4
1 files changed, 3 insertions, 1 deletions
diff --git a/app/helpers/application_settings_helper.rb b/app/helpers/application_settings_helper.rb
index b3b080e6dcf..3fbb32c5229 100644
--- a/app/helpers/application_settings_helper.rb
+++ b/app/helpers/application_settings_helper.rb
@@ -74,10 +74,12 @@ module ApplicationSettingsHelper
css_class = 'btn'
css_class << ' active' unless disabled
checkbox_name = 'application_setting[enabled_oauth_sign_in_sources][]'
+ name = Gitlab::Auth::OAuth::Provider.label_for(source)
label_tag(checkbox_name, class: css_class) do
check_box_tag(checkbox_name, source, !disabled,
- autocomplete: 'off') + Gitlab::Auth::OAuth::Provider.label_for(source)
+ autocomplete: 'off',
+ id: name.tr(' ', '_')) + name
end
end
end