Sha256: 1ea4896addbcb608656ff9f0f5604bead026ea0ace0cea20d899472bbb5ea2ca

Contents?: true

Size: 755 Bytes

Versions: 60

Compression:

Stored size: 755 Bytes

Contents

module HTTParty
  if defined?(::BasicObject)
    BasicObject = ::BasicObject #:nodoc:
  else
    class BasicObject #:nodoc:
      instance_methods.each { |m| undef_method m unless m =~ /^__|instance_eval/ }
    end
  end

  unless defined?(Net::HTTP::Patch)
    class Net::HTTP
      def patch(path, data, initheader = nil, dest = nil, &block) #:nodoc:
        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

      class Patch < Net::HTTPRequest
        METHOD = 'PATCH'
        REQUEST_HAS_BODY = true
        RESPONSE_HAS_BODY = true
      end
    end
  end
end

Version data entries

60 entries across 59 versions & 9 rubygems

Version Path
yoyle439587298-0.13.0 lib/httparty/core_extensions.rb
plyom_user-0.3.1 vendor/bundle/ruby/2.0.0/gems/httparty-0.11.0/lib/httparty/core_extensions.rb
plyom_user-0.3.0 vendor/bundle/ruby/2.0.0/gems/httparty-0.11.0/lib/httparty/core_extensions.rb
plyom_user-0.2.9 vendor/bundle/ruby/2.0.0/gems/httparty-0.11.0/lib/httparty/core_extensions.rb
plyom_user-0.2.8 vendor/bundle/ruby/2.0.0/gems/httparty-0.11.0/lib/httparty/core_extensions.rb
httparty-0.13.0 lib/httparty/core_extensions.rb
plyom_user-0.2.7 vendor/bundle/ruby/2.0.0/gems/httparty-0.11.0/lib/httparty/core_extensions.rb
plyom_user-0.2.6 vendor/bundle/ruby/2.0.0/gems/httparty-0.11.0/lib/httparty/core_extensions.rb
plyom_user-0.2.5 vendor/bundle/ruby/2.0.0/gems/httparty-0.11.0/lib/httparty/core_extensions.rb
plyom_user-0.2.4 vendor/bundle/ruby/2.0.0/gems/httparty-0.11.0/lib/httparty/core_extensions.rb
plyom_user-0.2.3 vendor/bundle/ruby/2.0.0/gems/httparty-0.11.0/lib/httparty/core_extensions.rb
plyom_user-0.2.2 vendor/bundle/ruby/2.0.0/gems/httparty-0.11.0/lib/httparty/core_extensions.rb
plyom_user-0.2.1 vendor/bundle/ruby/2.0.0/gems/httparty-0.11.0/lib/httparty/core_extensions.rb
plyom_user-0.2.0 vendor/bundle/ruby/2.0.0/gems/httparty-0.11.0/lib/httparty/core_extensions.rb
plyom_user-0.1.9 vendor/bundle/ruby/2.0.0/gems/httparty-0.11.0/lib/httparty/core_extensions.rb
plyom_user-0.1.8 vendor/bundle/ruby/2.0.0/gems/httparty-0.11.0/lib/httparty/core_extensions.rb
plyom_user-0.1.7 vendor/bundle/ruby/2.0.0/gems/httparty-0.11.0/lib/httparty/core_extensions.rb
plyom_user-0.1.6 vendor/bundle/ruby/2.0.0/gems/httparty-0.11.0/lib/httparty/core_extensions.rb
plyom_user-0.1.5 vendor/bundle/ruby/2.0.0/gems/httparty-0.11.0/lib/httparty/core_extensions.rb
plyom_user-0.1.4 vendor/bundle/ruby/2.0.0/gems/httparty-0.11.0/lib/httparty/core_extensions.rb