diff options
author | Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com> | 2015-02-06 01:20:55 +0300 |
---|---|---|
committer | Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com> | 2015-02-06 01:20:55 +0300 |
commit | 62ed1c537e9b8aa85d354b377f18083fb71b8e05 (patch) | |
tree | a1b75f804b2e9384190f9d591a2f2701ea8d31db /app/controllers/admin/dashboard_controller.rb | |
parent | dbca8c97588d1fcc4155b079eb54157991be3aa7 (diff) |
Explicitly define ordering in models using default_scope
Diffstat (limited to 'app/controllers/admin/dashboard_controller.rb')
-rw-r--r-- | app/controllers/admin/dashboard_controller.rb | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/app/controllers/admin/dashboard_controller.rb b/app/controllers/admin/dashboard_controller.rb index be19139c9b1..c491e5c7550 100644 --- a/app/controllers/admin/dashboard_controller.rb +++ b/app/controllers/admin/dashboard_controller.rb @@ -1,7 +1,7 @@ class Admin::DashboardController < Admin::ApplicationController def index - @projects = Project.order("created_at DESC").limit(10) - @users = User.order("created_at DESC").limit(10) - @groups = Group.order("created_at DESC").limit(10) + @projects = Project.limit(10) + @users = User.limit(10) + @groups = Group.limit(10) end end |