lib/mrkt/faraday_middleware/response.rb in mrkt-1.2.1 vs lib/mrkt/faraday_middleware/response.rb in mrkt-1.2.2
- old
+ new
@@ -1,12 +1,10 @@
-require 'faraday_middleware'
+require 'faraday/response/json'
module Mrkt
module FaradayMiddleware
- class Response < ::FaradayMiddleware::ParseJson
- define_parser do |body|
- JSON.parse(body, symbolize_names: true) unless body.strip.empty?
- end
+ class Response < ::Faraday::Response::Json
+ private
def process_response(env)
super
data = env[:body]