joshbuddy / jsonpath

Ruby implementation of http://goessner.net/articles/JsonPath/
MIT License
447 stars 72 forks source link

`symbolize_keys` option doesn't work as the README says #162

Open marciondg opened 1 year ago

marciondg commented 1 year ago

Hi everyone! Checking the README I found this interesting option

image

However, when I tested it in my project, it didn't work as expected

image

Looking over the implementation, I detected that it uses a symbolize_keys expected in the on options, ignoring the sent during the initialization. https://github.com/joshbuddy/jsonpath/blob/4e31ac9fc05eb309999903e674cd3a79763cb7a0/lib/jsonpath.rb#L79-L87

So, I tried as follows and it worked! image

Should the documentation be modified or rather the implementation? Thanks!

anupama-kumari commented 1 year ago

I have tried to fix above issue, kindly check @joshbuddy

https://github.com/joshbuddy/jsonpath/pull/165