czak-authlogic-oid 1.0.4 → 1.0.5
Sign up to get free protection for your applications and to get access to all the features.
- data/lib/authlogic_openid/session.rb +10 -2
- data/lib/authlogic_openid/version.rb +1 -1
- metadata +2 -2
@@ -72,14 +72,22 @@ module AuthlogicOpenid
|
|
72
72
|
end
|
73
73
|
|
74
74
|
def validate_by_openid
|
75
|
+
options = {}
|
76
|
+
options[:required] = klass.openid_required_fields
|
77
|
+
options[:optional] = klass.openid_optional_fields
|
78
|
+
options[:return_to] = controller.url_for(:for_session => "1")
|
79
|
+
options[:remember_me] = remember_me?
|
80
|
+
|
75
81
|
self.remember_me = controller.params[:remember_me] == "true" if controller.params.key?(:remember_me)
|
76
|
-
controller.send(:authenticate_with_open_id, openid_identifier,
|
82
|
+
controller.send(:authenticate_with_open_id, openid_identifier, options) do |result, openid_identifier, registration|
|
83
|
+
puts ">>>>>>>>>>>>>>>>" + registration.inspect
|
84
|
+
|
77
85
|
if result.unsuccessful?
|
78
86
|
errors.add_to_base(result.message)
|
79
87
|
return
|
80
88
|
end
|
81
89
|
|
82
|
-
self.attempted_record = klass.send(find_by_openid_identifier_method, openid_identifier)
|
90
|
+
self.attempted_record = klass.send(find_by_openid_identifier_method, openid_identifier, registration)
|
83
91
|
|
84
92
|
if !attempted_record
|
85
93
|
errors.add(:openid_identifier, I18n.t('authlogic.error_messages.no_openid_match', :default => "did not match any users in our database, have you set up your account to use OpenID?"))
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: czak-authlogic-oid
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.0.
|
4
|
+
version: 1.0.5
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Ben Johnson of Binary Logic
|
@@ -9,7 +9,7 @@ autorequire:
|
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
11
|
|
12
|
-
date: 2009-12-
|
12
|
+
date: 2009-12-14 00:00:00 +01:00
|
13
13
|
default_executable:
|
14
14
|
dependencies:
|
15
15
|
- !ruby/object:Gem::Dependency
|