HEX
Server: Apache
System: Linux s198.coreserver.jp 5.15.0-151-generic #161-Ubuntu SMP Tue Jul 22 14:25:40 UTC 2025 x86_64
User: nagasaki (10062)
PHP: 7.1.33
Disabled: NONE
Upload Files
File: //usr/local/rvm/gems/default/gems/actionpack-6.1.4.1/lib/action_controller/metal/logging.rb
# frozen_string_literal: true

module ActionController
  module Logging
    extend ActiveSupport::Concern

    module ClassMethods
      # Set a different log level per request.
      #
      #   # Use the debug log level if a particular cookie is set.
      #   class ApplicationController < ActionController::Base
      #     log_at :debug, if: -> { cookies[:debug] }
      #   end
      #
      def log_at(level, **options)
        around_action ->(_, action) { logger.log_at(level, &action) }, **options
      end
    end
  end
end