Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

x_auth_access_type can be passed in params

  • Loading branch information...
commit 120f6bf2e09211740df8fa96f3dd3fa252a95f58 1 parent 43c61ba
@arunagw authored
Showing with 5 additions and 0 deletions.
  1. +5 −0 lib/omniauth/strategies/twitter.rb
View
5 lib/omniauth/strategies/twitter.rb
@@ -38,10 +38,15 @@ def raw_info
def request_phase
screen_name = session['omniauth.params'] ? session['omniauth.params']['screen_name'] : nil
+ x_auth_access_type = session['omniauth.params'] ? session['omniauth.params']['x_auth_access_type'] : nil
if screen_name && !screen_name.empty?
options[:authorize_params] ||= {}
options[:authorize_params].merge!(:force_login => 'true', :screen_name => screen_name)
end
+ if x_auth_access_type
+ options[:request_params] || {}
+ options[:request_params].merge!(:x_auth_access_type => x_auth_access_type)
+ end
old_request_phase
end
Please sign in to comment.
Something went wrong with that request. Please try again.