Class: OmniAuth::Strategies::Qiita::AccessToken

Inherits:
OAuth2::AccessToken
  • Object
show all
Defined in:
lib/omniauth/strategies/qiita/access_token.rb

Class Method Summary collapse

Class Method Details

.from_hash_with_token(client, hash) ⇒ Object Also known as: from_hash



6
7
8
9
10
11
12
# File 'lib/omniauth/strategies/qiita/access_token.rb', line 6

def from_hash_with_token(client, hash)
  if hash['token']
    new(client, hash.delete('token') || hash.delete(:token), hash)
  else
    orig_from_hash
  end
end