summaryrefslogtreecommitdiffstats
path: root/app/models/news.rb
diff options
context:
space:
mode:
authorToshi MARUYAMA <marutosijp2@yahoo.co.jp>2014-01-09 07:06:50 +0000
committerToshi MARUYAMA <marutosijp2@yahoo.co.jp>2014-01-09 07:06:50 +0000
commiteb98a1f714d9169d826df20b7df2c4683142ebcc (patch)
treee000cd6cc16fb3e92e5644bba4b3ca4d23a99947 /app/models/news.rb
parenta6da09026a33a85cc37d040acdaafdfc0317ce34 (diff)
downloadredmine-eb98a1f714d9169d826df20b7df2c4683142ebcc.tar.gz
redmine-eb98a1f714d9169d826df20b7df2c4683142ebcc.zip
backout r12540 : remove unneeded Relation#all from News#latest
git-svn-id: http://svn.redmine.org/redmine/trunk@12566 e93f8b46-1217-0410-a6f0-8f06a7374b81
Diffstat (limited to 'app/models/news.rb')
-rw-r--r--app/models/news.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/app/models/news.rb b/app/models/news.rb
index a22947248..2186beaed 100644
--- a/app/models/news.rb
+++ b/app/models/news.rb
@@ -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