Class: OmniAuth::AuthHash::InfoHash
- Inherits:
-
Hashie::Mash
- Object
- Hashie::Mash
- OmniAuth::AuthHash::InfoHash
- Defined in:
- lib/omniauth/auth_hash.rb
Class Method Summary collapse
Instance Method Summary collapse
Class Method Details
.subkey_class ⇒ Object
28 |
# File 'lib/omniauth/auth_hash.rb', line 28 def self.subkey_class; Hashie::Mash end |
Instance Method Details
#name ⇒ Object
30 31 32 33 34 35 36 |
# File 'lib/omniauth/auth_hash.rb', line 30 def name return self[:name] if self[:name] return "#{first_name} #{last_name}".strip if first_name? || last_name? return nickname if nickname? return email if email? nil end |
#name? ⇒ Boolean
38 |
# File 'lib/omniauth/auth_hash.rb', line 38 def name?; !!name end |
#to_hash ⇒ Object
44 45 46 47 48 |
# File 'lib/omniauth/auth_hash.rb', line 44 def to_hash hash = super hash['name'] ||= name hash end |
#valid? ⇒ Boolean
40 41 42 |
# File 'lib/omniauth/auth_hash.rb', line 40 def valid? name? end |