lib/memolog/init.rb in memolog-0.4.6 vs lib/memolog/init.rb in memolog-0.4.7

- old
+ new

@@ -4,10 +4,11 @@ extend self def init_middlewares! init_rails_middleware! init_sidekiq_middleware! + init_sentry! end def init_rails_middleware! return unless Memolog.config.middlewares.include?(:rails) return unless Object.const_defined?(:Rails) @@ -23,7 +24,13 @@ Sidekiq.configure_server do |config| config.server_middleware do |chain| chain.prepend(Memolog::SidekiqMiddleware) end end + end + + def init_sentry! + return unless Object.const_defined?(:Sentry) + + Sentry.prepend(Memolog::SentryExtension) end end