aboutsummaryrefslogtreecommitdiffstats
path: root/activejob/lib/active_job/core.rb
diff options
context:
space:
mode:
authorMike Perham <mperham@gmail.com>2016-03-09 08:56:21 -0800
committerMike Perham <mperham@gmail.com>2016-03-09 08:56:21 -0800
commit702ef37767da7a32d34d29f8936c056d70e8fc56 (patch)
tree7d985c9cc946be4d400fa4d2ebbe24293e74d556 /activejob/lib/active_job/core.rb
parent5cd2beb0135faf18c978507a4be272dfc1499bb8 (diff)
downloadrails-702ef37767da7a32d34d29f8936c056d70e8fc56.tar.gz
rails-702ef37767da7a32d34d29f8936c056d70e8fc56.tar.bz2
rails-702ef37767da7a32d34d29f8936c056d70e8fc56.zip
Job payload should be symmetric across JSON dump/load
Placing non-native JSON data types, like symbols, in the hash to serialize means that the deserialize method will return something different from what was serialized, a common bug and source of frustration for devs.
Diffstat (limited to 'activejob/lib/active_job/core.rb')
-rw-r--r--activejob/lib/active_job/core.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/activejob/lib/active_job/core.rb b/activejob/lib/active_job/core.rb
index 19b900a285..0b32b7263c 100644
--- a/activejob/lib/active_job/core.rb
+++ b/activejob/lib/active_job/core.rb
@@ -79,7 +79,7 @@ module ActiveJob
'queue_name' => queue_name,
'priority' => priority,
'arguments' => serialize_arguments(arguments),
- 'locale' => I18n.locale
+ 'locale' => I18n.locale.to_s
}
end