Sha256: 70be729d21d02a3367beb770c70301bbbe9e5053218bb03886d8c6437b76a45e
Contents?: true
Size: 509 Bytes
Versions: 3
Compression:
Stored size: 509 Bytes
Contents
module Instapaper # Defines HTTP request methods module Request # Perform an HTTP POST request def post(path, options={}, raw=false) request(:post, path, options, raw) end private # Perform an HTTP request def request(method, path, options, raw=false) response = connection(raw).send(method) do |request| request.path = path_prefix + path request.body = options unless options.empty? end raw ? response : response.body end end end
Version data entries
3 entries across 3 versions & 1 rubygems
Version | Path |
---|---|
instapaper-0.3.0 | lib/instapaper/request.rb |
instapaper-0.2.1 | lib/instapaper/request.rb |
instapaper-0.2.0 | lib/instapaper/request.rb |