rescue_action (ActionController::Rescue)

    # File lib/action_controller/rescue.rb, line 114
          def rescue_action(exception)
            log_error(exception) if logger
            erase_results if performed?

            # Let the exception alter the response if it wants.
            # For example, MethodNotAllowed sets the Allow header.
            if exception.respond_to?(:handle_response!)
              exception.handle_response!(response)
            end

            if consider_all_requests_local || local_request?
              rescue_action_locally(exception)
            else
              rescue_action_in_public(exception)
            end
          end