backout r12540 : remove unneeded Relation#all from News#latest

git-svn-id: http://svn.redmine.org/redmine/trunk@12566 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
Toshi MARUYAMA 2014-01-09 07:06:50 +00:00
parent a6da09026a
commit eb98a1f714
1 changed files with 1 additions and 1 deletions

View File

@ -56,7 +56,7 @@ class News < ActiveRecord::Base
# returns latest news for projects visible by user
def self.latest(user = User.current, count = 5)
visible(user).includes([:author, :project]).order("#{News.table_name}.created_on DESC").limit(count)
visible(user).includes([:author, :project]).order("#{News.table_name}.created_on DESC").limit(count).all
end
private