class ActiveSupport::ErrorReporter
def subscribe(subscriber)
report(Exception, handled: Boolean, severity: (:error OR :warning OR :info), context: Hash, source: String)
Register a new error subscriber. The subscriber must respond to
def subscribe(subscriber) unless subscriber.respond_to?(:report) raise ArgumentError, "Error subscribers must respond to #report" end @subscribers << subscriber end