* Add multiple select to authentication providers configuration * Remove hardcoded providers from SiteConfig
17 lines
490 B
Ruby
17 lines
490 B
Ruby
module AuthenticationHelper
|
|
def authentication_provider(provider_name)
|
|
Authentication::Providers.get!(provider_name)
|
|
end
|
|
|
|
def authentication_available_providers
|
|
Authentication::Providers.available.map do |provider_name|
|
|
Authentication::Providers.const_get(provider_name.to_s.titleize)
|
|
end
|
|
end
|
|
|
|
def authentication_enabled_providers
|
|
Authentication::Providers.enabled.map do |provider_name|
|
|
Authentication::Providers.get!(provider_name)
|
|
end
|
|
end
|
|
end
|