Module: FriendlyErrors::ClassMethods

Defined in:
lib/friendly_errors.rb

Overview

Class method to mix into action controller.

Instance Method Summary collapse

Instance Method Details

#use_friendly_errors(filter_options = {}) ⇒ Object

:nodoc:



10
11
12
13
# File 'lib/friendly_errors.rb', line 10

def use_friendly_errors(filter_options = {})
  rescue_from ActiveRecord::RecordNotFound, :with => :record_not_found
  rescue_from ActionController::RedirectBackError, :with => :redirect_back_error
end