Skip to content

Commit

Permalink
use OpenID to do the URL normalization; this isn't in the rails plugi…
Browse files Browse the repository at this point in the history
…n anymore
  • Loading branch information
Michael Reinsch committed Mar 17, 2010
1 parent 8c242a5 commit 9b802c3
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions lib/authlogic_openid/acts_as_authentic.rb
Expand Up @@ -53,9 +53,9 @@ def self.included(klass)

# Set the openid_identifier field and also resets the persistence_token if this value changes.
def openid_identifier=(value)
write_attribute(:openid_identifier, value.blank? ? nil : OpenIdAuthentication.normalize_identifier(value))
write_attribute(:openid_identifier, value.blank? ? nil : OpenID.normalize_url(value))
reset_persistence_token if openid_identifier_changed?
rescue OpenIdAuthentication::InvalidOpenId => e
rescue OpenID::DiscoveryFailure => e
@openid_error = e.message
end

Expand Down
4 changes: 2 additions & 2 deletions lib/authlogic_openid/session.rb
Expand Up @@ -48,9 +48,9 @@ def credentials=(value)
end

def openid_identifier=(value)
@openid_identifier = value.blank? ? nil : OpenIdAuthentication.normalize_identifier(value)
@openid_identifier = value.blank? ? nil : OpenID.normalize_url(value)
@openid_error = nil
rescue OpenIdAuthentication::InvalidOpenId => e
rescue OpenID::DiscoveryFailure => e
@openid_identifier = nil
@openid_error = e.message
end
Expand Down

0 comments on commit 9b802c3

Please sign in to comment.