lib/omniauth/strategies/multi_password.rb in omniauth-multipassword-0.2.0 vs lib/omniauth/strategies/multi_password.rb in omniauth-multipassword-0.3.0

- old
+ new

@@ -50,16 +50,23 @@ def authenticate(username, password) @authenticators.each do |auth| begin @authenticator = auth[0].new @app, *auth[1] @authenticator.init_authenticator(@request, @env, username) - return true if @authenticator.authenticate(username, password) + if @authenticator.authenticate(username, password) + return true + end rescue Error => e OmniAuth.logger.warn "OmniAuth ERR >>> " + e end @authenticator = nil end false + end + + def name + return @authenticator.name if @authenticator + super end info do info = @authenticator.info if @authenticator info = {} unless info.is_a?(Hash)