lib/bullet.rb in bullet-5.7.6 vs lib/bullet.rb in bullet-5.8.0

- old
+ new

@@ -17,12 +17,12 @@ autoload :Notification, 'bullet/notification' autoload :Detector, 'bullet/detector' autoload :Registry, 'bullet/registry' autoload :NotificationCollector, 'bullet/notification_collector' - BULLET_DEBUG = 'BULLET_DEBUG'.freeze - TRUE = 'true'.freeze + BULLET_DEBUG = 'BULLET_DEBUG' + TRUE = 'true' if defined? Rails::Railtie class BulletRailtie < Rails::Railtie initializer 'bullet.configure_rails_initialization' do |app| app.middleware.use Bullet::Rack @@ -161,9 +161,10 @@ Thread.current[:bullet_notification_collector] end def notification? return unless start? + Bullet::Detector::UnusedEagerLoading.check_unused_preload_associations notification_collector.notifications_present? end def gather_inline_notifications