Class: OmniAuth::Strategies::TaskRabbit

Inherits:
OAuth2
  • Object
show all
Defined in:
lib/omniauth/strategies/taskrabbit.rb

Instance Method Summary collapse

Instance Method Details

#access_token_optionsObject



49
50
51
# File 'lib/omniauth/strategies/taskrabbit.rb', line 49

def access_token_options
  options.access_token_options.inject({}) { |h,(k,v)| h[k.to_sym] = v; h }
end

#build_access_tokenObject



43
44
45
46
47
# File 'lib/omniauth/strategies/taskrabbit.rb', line 43

def build_access_token
  super.tap do |token|
    token.options.merge!(access_token_options)
  end
end

#raw_infoObject



39
40
41
# File 'lib/omniauth/strategies/taskrabbit.rb', line 39

def raw_info
  @raw_info ||= access_token.get('/api/v1/account').parsed
end