Skip to content

Commit 9889717

Browse files
author
jamesprior
committed
Do not load tasks for deleted pages
1 parent e1009d5 commit 9889717

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

app/controllers/cms/dashboard_controller.rb

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ def index
66
@unpublished_pages = @unpublished_pages.select { |page| current_user.able_to_publish?(page) }
77
@incomplete_tasks = current_user.tasks.incomplete.
88
includes(:page).
9+
where(Page.table_name => {:deleted => false}).
910
order("#{Task.table_name}.due_date desc, #{Page.table_name}.name").
1011
references(:page)
1112
end

0 commit comments

Comments
 (0)