Class: Polar::User
Instance Method Summary collapse
- #avatar ⇒ Object
-
#initialize(data) ⇒ User
constructor
A new instance of User.
- #to_h ⇒ Object
Methods inherited from Base
Constructor Details
#initialize(data) ⇒ User
Returns a new instance of User.
3 4 5 |
# File 'lib/polar/user.rb', line 3 def initialize(data) super(data) end |
Dynamic Method Handling
This class handles dynamic methods through the method_missing method in the class Polar::Base
Instance Method Details
#avatar ⇒ Object
7 8 9 |
# File 'lib/polar/user.rb', line 7 def avatar tinyurl end |
#to_h ⇒ Object
11 12 13 |
# File 'lib/polar/user.rb', line 11 def to_h @data.merge({ "avatar" => @data["tinyurl"]}) end |