DEV: default Oj to compat mode
Out-of-the-box Oj uses :object mode, this shifts us to use :compat mode by default which is safer. It means any de-serialization going forward will default to this mode. If we wish to serialize or deserialize arbitrary objects going forward with no json interfaces we will have to opt in.
This commit is contained in:
parent
0bc65fa60e
commit
f8e92298f2
|
@ -3,6 +3,7 @@
|
|||
Oj::Rails.set_encoder()
|
||||
Oj::Rails.set_decoder()
|
||||
Oj::Rails.optimize()
|
||||
Oj.default_options = Oj.default_options.merge(mode: :compat)
|
||||
|
||||
# Not sure why it's not using this by default!
|
||||
MultiJson.engine = :oj
|
||||
|
|
Loading…
Reference in New Issue