Class: OmniAuth::Strategies::HackClub
- Inherits:
-
OAuth2
- Object
- OAuth2
- OmniAuth::Strategies::HackClub
- Defined in:
- lib/omniauth/strategies/hack_club.rb
Constant Summary collapse
- PRODUCTION_SITE =
'https://auth.hackclub.com'- STAGING_SITE =
'https://hca.dinosaurbbq.org'
Instance Method Summary collapse
Instance Method Details
#callback_url ⇒ Object
56 57 58 |
# File 'lib/omniauth/strategies/hack_club.rb', line 56 def callback_url full_host + callback_path end |
#client ⇒ Object
23 24 25 26 |
# File 'lib/omniauth/strategies/hack_club.rb', line 23 def client .[:site] = .staging ? STAGING_SITE : PRODUCTION_SITE super end |
#identity ⇒ Object
52 53 54 |
# File 'lib/omniauth/strategies/hack_club.rb', line 52 def identity raw_info['identity'] || {} end |
#raw_info ⇒ Object
48 49 50 |
# File 'lib/omniauth/strategies/hack_club.rb', line 48 def raw_info @raw_info ||= access_token.get('/api/v1/me').parsed end |