mirror of
https://github.com/TracksApp/tracks.git
synced 2025-12-28 12:58:48 +01:00
Normalize token, not URL
OpenID 2.0 supports tokens that aren't valid URLs
This commit is contained in:
parent
0dfb1aafda
commit
0e7c2a344c
1 changed files with 2 additions and 2 deletions
|
|
@ -157,7 +157,7 @@ class User < ActiveRecord::Base
|
|||
end
|
||||
|
||||
def self.find_by_open_id_url(raw_identity_url)
|
||||
normalized_open_id_url = OpenIdAuthentication.normalize_url(raw_identity_url)
|
||||
normalized_open_id_url = OpenIdAuthentication.normalize_identifier(raw_identity_url)
|
||||
find(:first, :conditions => ['open_id_url = ?', normalized_open_id_url])
|
||||
end
|
||||
|
||||
|
|
@ -248,6 +248,6 @@ protected
|
|||
|
||||
def normalize_open_id_url
|
||||
return if open_id_url.nil?
|
||||
self.open_id_url = OpenIdAuthentication.normalize_url(open_id_url)
|
||||
self.open_id_url = OpenIdAuthentication.normalize_identifier(open_id_url)
|
||||
end
|
||||
end
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue