summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJean-Philippe Lang <jp_lang@yahoo.fr>2012-11-27 19:24:22 +0000
committerJean-Philippe Lang <jp_lang@yahoo.fr>2012-11-27 19:24:22 +0000
commit04dcdb3290e0af847011d2c026579d255c1f4a6b (patch)
treec2fc4b7f40369b85c40ce76a1d740059f648bdb1
parent457f0bb337203a5aeaece95da6df7f3a0b490f12 (diff)
downloadredmine-04dcdb3290e0af847011d2c026579d255c1f4a6b.tar.gz
redmine-04dcdb3290e0af847011d2c026579d255c1f4a6b.zip
Code cleanup.
git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@10882 e93f8b46-1217-0410-a6f0-8f06a7374b81
-rw-r--r--app/models/user.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/app/models/user.rb b/app/models/user.rb
index 671431cce..264cbd14c 100644
--- a/app/models/user.rb
+++ b/app/models/user.rb
@@ -628,7 +628,7 @@ class User < Principal
next if user.hashed_password.blank?
salt = User.generate_salt
hashed_password = User.hash_password("#{salt}#{user.hashed_password}")
- User.update_all("salt = '#{salt}', hashed_password = '#{hashed_password}'", ["id = ?", user.id] )
+ User.where(:id => user.id).update_all(:salt => salt, :hashed_password => hashed_password)
end
end
end