summaryrefslogtreecommitdiff
path: root/app/helpers/auth_helper.rb
diff options
context:
space:
mode:
authorAndrei Gliga <otzy_007@yahoo.com>2016-05-04 13:36:15 +0300
committerAndrei Gliga <otzy_007@yahoo.com>2016-05-12 13:44:46 +0300
commitd943e5f691ad9c59e349eab95f1a21bd0f85ab1b (patch)
tree3fcc046ff49e45db47e7176820dfb9886892fc90 /app/helpers/auth_helper.rb
parent8d26836e945f3e66a46370905b9fb34244a0ff91 (diff)
downloadgitlab-ce-d943e5f691ad9c59e349eab95f1a21bd0f85ab1b.tar.gz
method to check if oauth button based providers are enabled
Diffstat (limited to 'app/helpers/auth_helper.rb')
-rw-r--r--app/helpers/auth_helper.rb4
1 files changed, 4 insertions, 0 deletions
diff --git a/app/helpers/auth_helper.rb b/app/helpers/auth_helper.rb
index 24eb813d0ba..3e1f4209254 100644
--- a/app/helpers/auth_helper.rb
+++ b/app/helpers/auth_helper.rb
@@ -44,6 +44,10 @@ module AuthHelper
button_based_providers.map(&:to_s) - disabled_providers
end
+ def button_based_providers_enabled?
+ !enabled_button_based_providers.empty?
+ end
+
def provider_image_tag(provider, size = 64)
label = label_for_provider(provider)