Sha256: be22cbc145a8a9c91a21a5c11829ec76e82f533c35746da7f28d91ba66e6926f
Contents?: true
Size: 431 Bytes
Versions: 1
Compression:
Stored size: 431 Bytes
Contents
require 'pushbullet/connection.rb' module Pushbullet module Request include Connection def get(path) request(:get, path) end def post(path, payload) request(:post, path, payload) end private def request(method, path, payload = {}) response = connection.send(method) {|request| request.url path request.body = payload if method == :post } end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
pushbullet-0.0.2 | lib/pushbullet/request.rb |