Sha256: 3a1b60a989c8ea8cb7b28b6aba992db1b60a9d49d598a6773030e8e1584d7796

Contents?: true

Size: 436 Bytes

Versions: 1

Compression:

Stored size: 436 Bytes

Contents

class Net::HTTP::Patch < Net::HTTP::Get
  METHOD = "PATCH"
end

# Definition of a patch method in the same way that post works
class Net::HTTP
  def patch(path, data, initheader = nil, dest = nil, &block) # :yield: +body_segment+
    res = nil
    request(Patch.new(path, initheader), data) {|r|
      r.read_body dest, &block
      res = r
    }
    unless @newimpl
      res.value
      return res, res.body
    end
    res
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
restfulie-0.8.0 lib/restfulie/client/http/core_ext/http.rb