Class: OmniAuth::Strategies::Etencent
- Inherits:
-
OAuth2
- Object
- OAuth2
- OmniAuth::Strategies::Etencent
- Defined in:
- lib/omniauth/strategies/etencent.rb
Instance Method Summary collapse
Instance Method Details
#authorize_params ⇒ Object
16 17 18 19 20 21 22 23 24 25 26 |
# File 'lib/omniauth/strategies/etencent.rb', line 16 def super.tap do |params| %w[scope client_options].each do |v| if request.params[v] params[v.to_sym] = request.params[v] # to support omniauth-oauth2's auto csrf protection session['omniauth.state'] = params[:state] if v == 'state' end end end end |
#authorizer_info ⇒ Object
50 51 52 |
# File 'lib/omniauth/strategies/etencent.rb', line 50 def @authorizer_info ||= access_token.to_hash.dig('authorizer_info') || {} end |
#request_phase ⇒ Object
58 59 60 61 |
# File 'lib/omniauth/strategies/etencent.rb', line 58 def request_phase session['omniauth.redirect_uri'] = callback_url super end |
#scope ⇒ Object
54 55 56 |
# File 'lib/omniauth/strategies/etencent.rb', line 54 def scope ['scope_list'] end |