Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- class ApplicationController < ActionController::Base
- rescue_from ActiveRecord::RecordNotFound, :with => :not_found
- private
- def not_found
- respond_to do |format|
- format.html { render not_found_action, :status => :not_found }
- format.all { head :not_found }
- end
- end
- def not_found_action
- "shared/404"
- end
- end
Add Comment
Please, Sign In to add comment