Sha256: 4d9c9e1b93aba608d2a654d04a9d1ff0d7c84434f5bd41ca8279fcdbb3b5a197
Contents?: true
Size: 719 Bytes
Versions: 18
Compression:
Stored size: 719 Bytes
Contents
require "logtail-rails/active_record/log_subscriber/logtail_log_subscriber" module Logtail module Integrations module ActiveRecord # Responsible for uninstalling the default `ActiveRecord::LogSubscriber` and replacing it # with the `LogtailLogSubscriber`. # # @private class LogSubscriber < Integrator def integrate! return true if Logtail::Integrations::Rails::ActiveSupportLogSubscriber.subscribed?(:active_record, LogtailLogSubscriber) Logtail::Integrations::Rails::ActiveSupportLogSubscriber.unsubscribe!(:active_record, ::ActiveRecord::LogSubscriber) LogtailLogSubscriber.attach_to(:active_record) end end end end end
Version data entries
18 entries across 18 versions & 1 rubygems