mirror of
https://github.com/LaCasemate/fab-manager.git
synced 2024-12-04 15:24:23 +01:00
12 lines
266 B
Ruby
12 lines
266 B
Ruby
module FabManager
|
|
module Middleware
|
|
class ServerLocale
|
|
def call(worker_class, job, queue)
|
|
locale = job['locale'] || Rails.application.secrets.rails_locale
|
|
I18n.with_locale(locale) do
|
|
yield
|
|
end
|
|
end
|
|
end
|
|
end
|
|
end |