diff options
author | Toshi MARUYAMA <marutosijp2@yahoo.co.jp> | 2014-01-09 00:05:14 +0000 |
---|---|---|
committer | Toshi MARUYAMA <marutosijp2@yahoo.co.jp> | 2014-01-09 00:05:14 +0000 |
commit | ca4dcdc3af4a61870f5fb6651c566d50492a55bb (patch) | |
tree | 909cf3abd9fb6c4767cdc958325bc2eb6d8d4047 /app/models/news.rb | |
parent | d9624990e0e2af5b52ed0a348460e6f13e1e7867 (diff) | |
download | redmine-ca4dcdc3af4a61870f5fb6651c566d50492a55bb.tar.gz redmine-ca4dcdc3af4a61870f5fb6651c566d50492a55bb.zip |
remove unneeded Relation#all from News#latest
git-svn-id: http://svn.redmine.org/redmine/trunk@12540 e93f8b46-1217-0410-a6f0-8f06a7374b81
Diffstat (limited to 'app/models/news.rb')
-rw-r--r-- | app/models/news.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/app/models/news.rb b/app/models/news.rb index 2186beaed..a22947248 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).all + visible(user).includes([:author, :project]).order("#{News.table_name}.created_on DESC").limit(count) end private |