Commit 7a073b50 authored by dgt's avatar dgt

Fix: remove empty entries from page list

empty entries occur if we have page_terms for a non-existing page
parent 865ca6d1
......@@ -9,7 +9,7 @@ class Me::PagesController < Me::BaseController
if request.xhr?
# note: pagination_params is used just for defaults,
# normal pagination is done through @path.
@pages = Page.paginate_by_path(@path, options_for_me(method: :sphinx), pagination_params)
@pages = Page.paginate_by_path(@path, options_for_me(method: :sphinx), pagination_params).compact
end
render template: 'common/pages/search/index', locals: { columns: :updated_with_owner }
end
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment