diff options
author | Jean-Philippe Lang <jp_lang@yahoo.fr> | 2011-03-28 20:56:28 +0000 |
---|---|---|
committer | Jean-Philippe Lang <jp_lang@yahoo.fr> | 2011-03-28 20:56:28 +0000 |
commit | af968bfb226414aa6ae3b43cc94e6eb9d09d9d89 (patch) | |
tree | f9ecabb421b2628e0315cb7258eccfe3c821fafe | |
parent | ba0c9069ed64db6b4fea7f3f1759dbe064c867f7 (diff) | |
download | redmine-af968bfb226414aa6ae3b43cc94e6eb9d09d9d89.tar.gz redmine-af968bfb226414aa6ae3b43cc94e6eb9d09d9d89.zip |
Save queries.
git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@5245 e93f8b46-1217-0410-a6f0-8f06a7374b81
-rw-r--r-- | app/models/issue.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/app/models/issue.rb b/app/models/issue.rb index 21c721c94..24258b424 100644 --- a/app/models/issue.rb +++ b/app/models/issue.rb @@ -106,7 +106,7 @@ class Issue < ActiveRecord::Base # Overrides Redmine::Acts::Customizable::InstanceMethods#available_custom_fields def available_custom_fields - (project && tracker) ? project.all_issue_custom_fields.select {|c| tracker.custom_fields.include? c } : [] + (project && tracker) ? (project.all_issue_custom_fields & tracker.custom_fields.all) : [] end def copy_from(arg) |