Sha256: 0048c19c845f34a4440f447373826f706827316cd9b28b092575fe64e958ebec
Contents?: true
Size: 820 Bytes
Versions: 38
Compression:
Stored size: 820 Bytes
Contents
unless RestClient.const_defined? :OAUTH_EXTENSION RestClient::OAUTH_EXTENSION = lambda do |request, args| if args[:oauth] uri = URI.parse args[:url] default_options = { :site => "#{uri.scheme}://#{uri.host}:#{uri.port.to_s}", :request_token_path => "", :authorize_path => "", :access_token_path => "" } options = default_options.merge args[:oauth][:options] || { } consumer = OAuth::Consumer.new(args[:oauth][:consumer_key], args[:oauth][:consumer_secret], options) consumer.sign!(request) end end end unless RestClient.before_execution_procs.include? RestClient::OAUTH_EXTENSION RestClient.add_before_execution_proc &RestClient::OAUTH_EXTENSION end
Version data entries
38 entries across 38 versions & 4 rubygems