Class: OmniAuth::Strategies::Redbooth

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

Overview

Constant Summary collapse

REDBOOTH_URL =
'https://redbooth.com'.freeze

Instance Method Summary collapse

Instance Method Details

#callback_urlObject

This is needed in order to support omniauth-oauth2 1.4.0, as for this version they made the gem more supportive of the OAuth2 standard, unfortunately not all OAuth2 providers support it.

Theres more information about it here:

github.com/intridea/omniauth-oauth2/issues/81



37
38
39
# File 'lib/omniauth/strategies/redbooth.rb', line 37

def callback_url
  full_host + script_name + callback_path
end

#raw_infoObject



41
42
43
44
# File 'lib/omniauth/strategies/redbooth.rb', line 41

def raw_info
  @raw_info ||=
    access_token.get("#{options[:client_options][:site]}/me").parsed
end