lib/riak/map_reduce.rb in ripple-0.5.0 vs lib/riak/map_reduce.rb in ripple-0.5.1

- old
+ new

@@ -133,10 +133,10 @@ # Executes this map-reduce job. # @return [Array<Array>] similar to link-walking, each element is an array of results from a phase where "keep" is true. If there is only one "keep" phase, only the results from that phase will be returned. def run response = @client.http.post(200, @client.mapred, to_json, {"Content-Type" => "application/json", "Accept" => "application/json"}) if response.try(:[], :headers).try(:[],'content-type').include?("application/json") - JSON.parse(response[:body]) + ActiveSupport::JSON.decode(response[:body]) else response end rescue FailedRequest => fr if fr.code == 500 && fr.headers['content-type'].include?("application/json")