Sha256: 6d2af14190a08d1b1e14d31a82109fb1fd95db83fe28702f99e3b451181cd4d3
Contents?: true
Size: 318 Bytes
Versions: 11
Compression:
Stored size: 318 Bytes
Contents
class Grape::Batch::Response def self.format(status, headers, response) if response body = response.respond_to?(:body) ? response.body.join : response.join result = MultiJson.decode(body) end (200..299).include?(status) ? {success: result} : {code: status, error: result['error']} end end
Version data entries
11 entries across 11 versions & 1 rubygems