devise_rpx_connectable 0.1.1 → 0.1.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
data/README.textile
CHANGED
|
@@ -174,7 +174,7 @@ h2. Contributors
|
|
|
174
174
|
h2. Thanks
|
|
175
175
|
|
|
176
176
|
The base of this gem was heavily inspired from the "Devise Facebook Connectable gem":http://github.com/grimen/devise_facebook_connectable by "Jonas Grimfelt":http://github.com/grimen and other Devise gems.
|
|
177
|
-
This gem also
|
|
177
|
+
This gem also uses the great "rpx_now":http://github.com/grosser/rpx_now by "Michael Grosser":http://github.com/grosser
|
|
178
178
|
|
|
179
179
|
h2. License
|
|
180
180
|
|
|
@@ -19,10 +19,10 @@ module Devise #:nodoc:
|
|
|
19
19
|
def authenticate!
|
|
20
20
|
klass = mapping.to
|
|
21
21
|
begin
|
|
22
|
-
|
|
23
22
|
rpx_user = (RPXNow.user_data(params[:token]) rescue nil)
|
|
23
|
+
fail!(:rpx_invalid) and return unless rpx_user
|
|
24
24
|
|
|
25
|
-
if
|
|
25
|
+
if user = klass.authenticate_with_rpx(:identifier => rpx_user["identifier"])
|
|
26
26
|
success!(user)
|
|
27
27
|
else
|
|
28
28
|
if klass.rpx_auto_create_account?
|