Class: FlatpagesController

Inherits:
ApplicationController
  • Object
show all
Defined in:
app/controllers/flatpages_controller.rb

Instance Method Summary collapse

Instance Method Details

#showObject

Public: Show flatpage

Returns text/html

Raises:

  • (ActiveRecord::RecordNotFound)


5
6
7
8
# File 'app/controllers/flatpages_controller.rb', line 5

def show
  @page = Flatpage.find_by_path(params[:path])
  raise ActiveRecord::RecordNotFound unless @page.present?
end