Sha256: 89235696f009ea6e95af78f1f9ac0f47a1319fd2b92f241cbb80cd767003e3df
Contents?: true
Size: 297 Bytes
Versions: 2
Compression:
Stored size: 297 Bytes
Contents
require "json" class Kek class JSONParser < Faraday::Middleware def initialize(app) super(app) end def call(request) @app.call(request).on_complete do |response| response[:body] = JSON.parse(response[:body], symbolize_names: true) end end end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
kek-1.1.0 | lib/kek/json.rb |
kek-1.0.0 | lib/kek/json.rb |