method

_handle_path_relative_redirect

rails latest stable - Class: ActionController::Redirecting

Method not available on this version

This method is only available on newer versions. The first available version (v8.1.1) is shown here.

_handle_path_relative_redirect(url)
private

No documentation available.

# File actionpack/lib/action_controller/metal/redirecting.rb, line 327
      def _handle_path_relative_redirect(url)
        message = "Path relative URL redirect detected: #{url.inspect}"

        case action_on_path_relative_redirect
        when :log
          logger&.warn message
        when :notify
          ActiveSupport::Notifications.instrument("unsafe_redirect.action_controller",
            url: url,
            message: message,
            stack_trace: caller
          )
        when :raise
          raise PathRelativeRedirectError.new(url)
        end
      end