Parent

Methods

Faraday::Request::OAuth

Public Class Methods

new(app, options) click to toggle source
# File lib/faraday/request/oauth.rb, line 19
def initialize(app, options)
  @app, @options = app, options
end

Public Instance Methods

call(env) click to toggle source
# File lib/faraday/request/oauth.rb, line 7
def call(env)
  params = env[:body] || {}

  signature_params = params.reject{ |k,v| 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

[Validate]

Generated with the Darkfish Rdoc Generator 2.