mirror of
https://github.com/codeninjasllc/discourse.git
synced 2024-11-23 23:58:31 -05:00
22 lines
282 B
Ruby
22 lines
282 B
Ruby
class TopicPostCountSerializer < BasicUserSerializer
|
|
|
|
attributes :post_count
|
|
|
|
def id
|
|
object[:user].id
|
|
end
|
|
|
|
def username
|
|
object[:user].username
|
|
end
|
|
|
|
def avatar_template
|
|
object[:user].avatar_template
|
|
end
|
|
|
|
def post_count
|
|
object[:post_count]
|
|
end
|
|
|
|
|
|
end
|