mirror of
https://github.com/discourse/discourse.git
synced 2024-11-27 23:16:20 +08:00
15 lines
318 B
Ruby
15 lines
318 B
Ruby
# frozen_string_literal: true
|
|
|
|
# The most basic attributes of a topic that we need to create a link for it.
|
|
class PostWordpressSerializer < BasicPostSerializer
|
|
attributes :post_number
|
|
|
|
def avatar_template
|
|
if object.user
|
|
UrlHelper.absolute object.user.avatar_template
|
|
else
|
|
nil
|
|
end
|
|
end
|
|
end
|