MultiJson::Adapters::Oj#load ignores :symbolize_keys when it's false #105

merged 1 commit into from Mar 22, 2013


None yet
3 participants

7even commented Mar 22, 2013

MultiJson::Adapters::Oj#load ignores the :symbolize_keys option when it's false. It matters if I set the default Oj behaviour to symbolize keys:

Oj.default_options = { symbol_keys: true }

and then try to parse one string without symbolizing:

MultiJson.load('{"a":1}', symbolize_keys: false)
# => {:a=>1}

This pull request fixes the problem.

Coverage remained the same when pulling 9500cab on 7even:oj_symbolize_keys into 238db3e on intridea:master.

View Details

rwz added a commit that referenced this pull request Mar 22, 2013

Merge pull request #105 from 7even/oj_symbolize_keys
MultiJson::Adapters::Oj#load ignores :symbolize_keys when it's false

@rwz rwz merged commit 46ff924 into intridea:master Mar 22, 2013

1 check passed

default The Travis build passed

rwz commented Mar 22, 2013

Thanks! I also think that symbolize_keys should be default to override Oj.default_options

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment