Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Use mb_chars when downcasing login to deal with international characters
  • Loading branch information
binarylogic committed Jul 2, 2009
1 parent e44e1e3 commit 5383419
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 3 deletions.
4 changes: 2 additions & 2 deletions README.rdoc
Expand Up @@ -203,13 +203,13 @@ From rubyforge:

$ sudo gem install authlogic

OR from github:
Or from github:

$ sudo gem install binarylogic-authlogic

Now just add the gem dependency in your projects configuration.

Or you install this as a plugin (for older versions of rails)
Or you can install this as a plugin:

script/plugin install git://github.com/binarylogic/authlogic.git

Expand Down
1 change: 1 addition & 0 deletions authlogic.gemspec
Expand Up @@ -19,6 +19,7 @@ Gem::Specification.new do |s|
"README.rdoc",
"Rakefile",
"VERSION.yml",
"authlogic.gemspec",
"generators/session/session_generator.rb",
"generators/session/templates/session.rb",
"init.rb",
Expand Down
2 changes: 1 addition & 1 deletion lib/authlogic/acts_as_authentic/login.rb
Expand Up @@ -118,7 +118,7 @@ def find_with_case(field, value, sensitivity = true)
if sensitivity
send("find_by_#{field}", value)
else
first(:conditions => ["LOWER(#{quoted_table_name}.#{field}) = ?", value.downcase])
first(:conditions => ["LOWER(#{quoted_table_name}.#{field}) = ?", value.mb_chars.downcase])
end
end
end
Expand Down

0 comments on commit 5383419

Please sign in to comment.