Sha256: feeb29f21c3c34136acb246adaaf8ed8a394d630ee8cb8a304ca96d311c5650a
Contents?: true
Size: 556 Bytes
Versions: 6
Compression:
Stored size: 556 Bytes
Contents
require 'faraday' module Faraday class Request::AngellistApiOAuth < Faraday::Middleware dependency 'simple_oauth' def call(env) params = env[:body] || {} signature_params = params params.map{ |k,v| signature_params = {} if v.respond_to?(:content_type) } header = SimpleOAuth::Header.new(env[:method], env[:url], signature_params, @options) env[:request_headers]['Authorization'] = header.to_s @app.call(env) end def initialize(app, options) @app, @options = app, options end end end
Version data entries
6 entries across 6 versions & 1 rubygems