Class: Sidekiq::Middleware::I18n::Client

Inherits:
Object
  • Object
show all
Defined in:
lib/sidekiq/middleware/i18n.rb

Overview

Get the current locale and store it in the message to be sent to Sidekiq.

Instance Method Summary collapse

Instance Method Details

#call(worker_class, msg, queue, redis_pool) ⇒ Object



12
13
14
15
# File 'lib/sidekiq/middleware/i18n.rb', line 12

def call(worker_class, msg, queue, redis_pool)
  msg['locale'] ||= I18n.locale
  yield
end