Parse JSON with Ruby -


i have 2 json returns.

one able parse fine

{"login"=>"foo", "id"=>bar, 

with

@foobar_collect["login"] 

but 1 having issues with

{"items"=>[{"user_id"=>foo, "user_type"=>"bar",  

i try

@foobar_collect["items"]["user_id"] 

and gives me error no implicit conversion of string integer

what doing wrong?

@foobar_collect["items"].first["user_id"] 

Comments

Popular posts from this blog

matlab - Deleting rows with specific rules -

jquery - How would i go about shortening this code? And to cancel the previous click on click of new section? -