Class: YiffSpace::Auth::UserInfo::Anonymous
- Inherits:
-
Object
- Object
- YiffSpace::Auth::UserInfo::Anonymous
- Includes:
- Singleton
- Defined in:
- lib/yiffspace/auth/user_info/anonymous.rb
Class Method Summary collapse
Instance Method Summary collapse
- #anonymous? ⇒ Boolean
- #avatar ⇒ Object
- #avatar_url ⇒ Object
- #banner ⇒ Object
- #banner_url ⇒ Object
- #blank? ⇒ Boolean
- #display_name ⇒ Object
-
#present? ⇒ Boolean
this feels wrong, but it hopefully shouldn’t break anything.
- #serializable_hash ⇒ Object
- #to_session ⇒ Object
- #username ⇒ Object
Class Method Details
.from_json ⇒ Object
60 61 62 |
# File 'lib/yiffspace/auth/user_info/anonymous.rb', line 60 def self.from_json(*) Anonymous.new end |
.from_session(data) ⇒ Object
64 65 66 67 68 |
# File 'lib/yiffspace/auth/user_info/anonymous.rb', line 64 def self.from_session(data) return nil if data.blank? from_json(data) end |
Instance Method Details
#anonymous? ⇒ Boolean
39 40 41 |
# File 'lib/yiffspace/auth/user_info/anonymous.rb', line 39 def anonymous? true end |
#avatar ⇒ Object
23 24 25 |
# File 'lib/yiffspace/auth/user_info/anonymous.rb', line 23 def avatar nil end |
#avatar_url ⇒ Object
27 28 29 |
# File 'lib/yiffspace/auth/user_info/anonymous.rb', line 27 def avatar_url nil end |
#banner ⇒ Object
31 32 33 |
# File 'lib/yiffspace/auth/user_info/anonymous.rb', line 31 def nil end |
#banner_url ⇒ Object
35 36 37 |
# File 'lib/yiffspace/auth/user_info/anonymous.rb', line 35 def nil end |
#blank? ⇒ Boolean
48 49 50 |
# File 'lib/yiffspace/auth/user_info/anonymous.rb', line 48 def blank? true end |
#display_name ⇒ Object
19 20 21 |
# File 'lib/yiffspace/auth/user_info/anonymous.rb', line 19 def display_name "Anonymous" end |
#present? ⇒ Boolean
this feels wrong, but it hopefully shouldn’t break anything
44 45 46 |
# File 'lib/yiffspace/auth/user_info/anonymous.rb', line 44 def present? false end |
#serializable_hash ⇒ Object
52 53 54 |
# File 'lib/yiffspace/auth/user_info/anonymous.rb', line 52 def serializable_hash(*) nil end |
#to_session ⇒ Object
56 57 58 |
# File 'lib/yiffspace/auth/user_info/anonymous.rb', line 56 def to_session serializable_hash end |
#username ⇒ Object
15 16 17 |
# File 'lib/yiffspace/auth/user_info/anonymous.rb', line 15 def username "anonymous" end |