1
0
mirror of https://github.com/LaCasemate/fab-manager.git synced 2025-01-29 18:52:22 +01:00

[bug taiga#21] undefined method[] on notify_admin_profile_complete

This commit is contained in:
Sylvain 2016-04-12 14:18:07 +02:00
parent d1a9a69d14
commit ef72d07a9e

View File

@ -5,6 +5,10 @@ class AuthProvider < ActiveRecord::Base
def providable_type
DatabaseProvider.name
end
def name
'DatabaseProvider::SimpleAuthProvider'
end
end
PROVIDABLE_TYPES = %w(DatabaseProvider OAuth2Provider)
@ -39,6 +43,9 @@ class AuthProvider < ActiveRecord::Base
## Get the provider matching the omniAuth strategy name
def self.from_strategy_name(strategy_name)
if strategy_name.blank? or all.empty?
return SimpleAuthProvider.new
end
parsed = /^([^-]+)-(.+)$/.match(strategy_name)
ret = nil
all.each do |strategy|