discourse/app/serializers/search_topic_list_item_seri...

13 lines
208 B
Ruby

class SearchTopicListItemSerializer < ListableTopicSerializer
attributes :tags,
:category_id
def include_tags?
SiteSetting.tagging_enabled
end
def tags
object.tags.map(&:name)
end
end