Skip to content

Commit 34ffd8e

Browse files
committed
Handle error_handler change in Sidekiq 7.1.6
1 parent cca0312 commit 34ffd8e

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

lib/rails_semantic_logger/sidekiq/defaults.rb

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,8 @@ module RailsSemanticLogger
22
module Sidekiq
33
module Defaults
44
# Prevent exception logging during standard error handling since the Job Logger below already logs the exception.
5-
if ::Sidekiq::VERSION.to_f < 7.2
5+
if ::Sidekiq::VERSION.to_f < 7.1 ||
6+
(::Sidekiq::VERSION.to_f == 7.1 && ::Sidekiq::VERSION.split(".").last.to_i < 6)
67
ERROR_HANDLER = ->(ex, ctx) do
78
unless ctx.empty?
89
job_hash = ctx[:job] || {}

0 commit comments

Comments
 (0)