File tree Expand file tree Collapse file tree 1 file changed +4
-3
lines changed
lib/rails_semantic_logger/extensions/sidekiq Expand file tree Collapse file tree 1 file changed +4
-3
lines changed Original file line number Diff line number Diff line change @@ -101,8 +101,8 @@ def self.job_hash_context(job_hash)
101101 end
102102
103103 # Exception is already logged by Semantic Logger during the perform call
104- # Sidekiq <= v6.5
105104 if defined? ( ::Sidekiq ::ExceptionHandler )
105+ # Sidekiq <= v6.5
106106 module ExceptionHandler
107107 class Logger
108108 def call ( _exception , ctx )
@@ -115,8 +115,8 @@ def call(_exception, ctx)
115115 end
116116 end
117117 end
118- # Sidekiq >= v7
119118 elsif defined? ( ::Sidekiq ::Config )
119+ # Sidekiq >= v7
120120 class Config
121121 remove_const :ERROR_HANDLER
122122
@@ -198,7 +198,8 @@ def self.included(base)
198198 end
199199 end
200200
201- if Sidekiq ::VERSION . to_i == 4
201+ if defined? ( ::Sidekiq ::Middleware ::Server ::Logging )
202+ # Sidekiq v4
202203 # Convert string to machine readable format
203204 class Processor
204205 def log_context ( job_hash )
You can’t perform that action at this time.
0 commit comments