mirror of
https://github.com/codeninjasllc/discourse.git
synced 2024-11-24 08:09:13 -05:00
Merge pull request #3750 from tgxworld/fix_broken_serializer
FIX: Broken BasicUserSerializer.
This commit is contained in:
commit
43f8b2b41a
1 changed files with 2 additions and 2 deletions
|
@ -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
|
||||
|
||||
|
|
Loading…
Reference in a new issue