]> source.dussan.org Git - redmine.git/commitdiff
Use .klass instead of .class_name.constantize.
authorJean-Philippe Lang <jp_lang@yahoo.fr>
Sat, 24 Jan 2015 10:47:21 +0000 (10:47 +0000)
committerJean-Philippe Lang <jp_lang@yahoo.fr>
Sat, 24 Jan 2015 10:47:21 +0000 (10:47 +0000)
git-svn-id: http://svn.redmine.org/redmine/trunk@13939 e93f8b46-1217-0410-a6f0-8f06a7374b81

app/helpers/issues_helper.rb

index a618a68e77dfd0f44e7f7880fedab14bd857a889..5706bf53d20975125a911137937ba8d242cf98bb 100644 (file)
@@ -408,7 +408,7 @@ module IssuesHelper
     @detail_value_name_by_reflection ||= Hash.new do |hash, key|
       association = Issue.reflect_on_association(key.first.to_sym)
       if association
-        record = association.class_name.constantize.find_by_id(key.last)
+        record = association.klass.find_by_id(key.last)
         if record
           record.name.force_encoding('UTF-8')
           hash[key] = record.name