# File lib/twitter/json_stream.rb, line 323 def oauth_header uri = uri_base + @options[:path].to_s # The hash SimpleOAuth accepts is slightly different from that of # ROAuth. To preserve backward compatability, fix the cache here # so that the arguments passed in don't need to change. oauth = { :consumer_key => @options[:oauth][:consumer_key], :consumer_secret => @options[:oauth][:consumer_secret], :token => @options[:oauth][:access_key], :token_secret => @options[:oauth][:access_secret] } data = ['POST', 'PUT'].include?(@options[:method]) ? params : {} SimpleOAuth::Header.new(@options[:method], uri, data, oauth) end