Actually allow false as a value for sidekiq.backtrace in our Sidekiq
middleware
This commit is contained in:
parent
fadd707ae0
commit
f23fb6b6cb
1 changed files with 2 additions and 1 deletions
|
|
@ -5,7 +5,8 @@ module SidekiqMiddlewares
|
|||
rescue Exception
|
||||
backtrace = Rails.backtrace_cleaner.clean($!.backtrace)
|
||||
backtrace.reject! { |line| line =~ /lib\/sidekiq_middlewares.rb/ }
|
||||
limit = AppConfig.environment.sidekiq.backtrace.to_i
|
||||
limit = AppConfig.environment.sidekiq.backtrace.get
|
||||
limit = limit ? limit.to_i : 0
|
||||
backtrace = [] if limit == 0
|
||||
raise $!, $!.message, backtrace[0..limit]
|
||||
end
|
||||
|
|
|
|||
Loading…
Reference in a new issue