Fixes #2170: user display format in application settings broken by r2010.
git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@2031 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
parent
243027e63a
commit
7c1d8ac00b
|
@ -125,7 +125,11 @@ class User < ActiveRecord::Base
|
|||
|
||||
# Return user's full name for display
|
||||
def name(formatter = nil)
|
||||
@name ||= eval('"' + (USER_FORMATS[formatter || Setting.user_format] || USER_FORMATS[:firstname_lastname]) + '"')
|
||||
if formatter
|
||||
eval('"' + (USER_FORMATS[formatter] || USER_FORMATS[:firstname_lastname]) + '"')
|
||||
else
|
||||
@name ||= eval('"' + (USER_FORMATS[Setting.user_format] || USER_FORMATS[:firstname_lastname]) + '"')
|
||||
end
|
||||
end
|
||||
|
||||
def active?
|
||||
|
|
Loading…
Reference in New Issue