summaryrefslogtreecommitdiffstats
path: root/app/models
diff options
context:
space:
mode:
authorJean-Philippe Lang <jp_lang@yahoo.fr>2015-05-10 12:57:16 +0000
committerJean-Philippe Lang <jp_lang@yahoo.fr>2015-05-10 12:57:16 +0000
commit738ecf13654cbad7de53af516d13b004bead4ff3 (patch)
tree29a3ab7913b9de88eacf418b6c2796dfb444d9c9 /app/models
parentc8fb0956d15b8518c4fa38cc0ed5acff52e4c4b8 (diff)
downloadredmine-738ecf13654cbad7de53af516d13b004bead4ff3.tar.gz
redmine-738ecf13654cbad7de53af516d13b004bead4ff3.zip
Test broken by r14265 (#19458).
git-svn-id: http://svn.redmine.org/redmine/trunk@14266 e93f8b46-1217-0410-a6f0-8f06a7374b81
Diffstat (limited to 'app/models')
-rw-r--r--app/models/user.rb3
1 files changed, 2 insertions, 1 deletions
diff --git a/app/models/user.rb b/app/models/user.rb
index 3ecf03c18..ebfd02ea0 100644
--- a/app/models/user.rb
+++ b/app/models/user.rb
@@ -325,7 +325,8 @@ class User < Principal
# Returns true if the user password has expired
def password_expired?
- if Setting.password_max_age.to_i.zero?
+ period = Setting.password_max_age.to_i
+ if period.zero?
false
else
changed_on = self.passwd_changed_on || Time.at(0)