Skip to content

Commit

Permalink
#4 Redirect old slugs to news
Browse files Browse the repository at this point in the history
  • Loading branch information
marjinal1st committed Jan 4, 2014
1 parent cfbe1e9 commit 841bbf2
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion app/controllers/kebapage/static_pages_controller.rb
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,11 @@ def index
end

def show
render layout: 'layouts/application'
if request.path != main_app.pages_path(@static_page)
redirect_to main_app.pages_path(@static_page), status: :moved_permanently
else
render layout: 'layouts/application'
end
end

def new
Expand Down

0 comments on commit 841bbf2

Please sign in to comment.