module S3lite::Parse

Public Class Methods

json(txt) click to toggle source
# File lib/s3lite/parse.rb, line 3
def json(txt)
  case txt.class.to_s
  when 'String' then JSON.parse(txt, symbolize_names: true)
  when 'Hash', 'Array' then json(txt.to_json)
  end
end