Module: RocketCMS::Controllers::Pages

Extended by:
ActiveSupport::Concern
Included in:
PagesController
Defined in:
lib/rocket_cms/controllers/pages.rb

Instance Method Summary collapse

Instance Method Details

#showObject


5
6
7
8
9
10
11
12
13
14
# File 'lib/rocket_cms/controllers/pages.rb', line 5

def show
  if @seo_page.nil? || !@seo_page.persisted?
    unless params[:id].blank?
      @seo_page = Page.enabled.find(params[:id])
    end
  end
  if @seo_page.nil?
    render_404
  end
end