Class: Socialmux::AuthMapper::GuessName

Inherits:
Base
  • Object
show all
Defined in:
lib/socialmux/auth_mapper/guess_name.rb

Direct Known Subclasses

Github, Instagram, Twitter

Instance Attribute Summary

Attributes inherited from Base

#data

Instance Method Summary collapse

Methods inherited from Base

#gender, #initialize, #url

Constructor Details

This class inherits a constructor from Socialmux::AuthMapper::Base

Instance Method Details

#first_nameObject



4
5
6
# File 'lib/socialmux/auth_mapper/guess_name.rb', line 4

def first_name
  name_chunks.first || ""
end

#last_nameObject



8
9
10
11
12
# File 'lib/socialmux/auth_mapper/guess_name.rb', line 8

def last_name
  last_name = name_chunks.dup
  last_name.shift
  last_name.join(" ")
end