FIX: Broken BasicUserSerializer.

This commit is contained in:
Guo Xiang Tan 2015-09-11 11:54:08 +08:00
parent 90d49d1497
commit 98e8b16c34
1 changed files with 2 additions and 2 deletions

View File

@ -9,7 +9,7 @@ class BasicUserSerializer < ApplicationSerializer
if Hash === object
User.avatar_template(user[:username], user[:uploaded_avatar_id])
else
object.avatar_template
user.try(:avatar_template)
end
end
@ -21,7 +21,7 @@ class BasicUserSerializer < ApplicationSerializer
if Hash === object
User.letter_avatar_color(user[:username])
else
object.letter_avatar_color
user.try(:letter_avatar_color)
end
end