instance method consumes?

Ruby on Rails edge

Since edge

Signature

consumes?(name)

Whether an event with this name would currently be logged, so that the event reporter can skip building events this subscriber would discard. Deliberately not memoized: the answer changes with the logger’s level.

Parameters

name req
Source
# File activesupport/lib/active_support/event_reporter/log_subscriber.rb, line 67
      def consumes?(name)
        return false unless logger

        log_level_satisfied?(self.class.event_method_for(name))
      end

Defined in activesupport/lib/active_support/event_reporter/log_subscriber.rb line 67 · View on GitHub · Improve this page · Find usages on GitHub

Defined in ActiveSupport::EventReporter::LogSubscriber

Type at least 2 characters to search.

Use the arrow keys to navigate results, Enter to open one, Escape to close.

Keyboard shortcuts

/
Focus search
⌘K / Ctrl-K
Command palette
?
This help
Esc
Close