PERF: Remove N+1 queries on user messages page.

This commit is contained in:
Guo Xiang Tan
2016-06-28 10:01:00 +08:00
parent b4cb2e367c
commit e221414935
5 changed files with 9 additions and 5 deletions

View File

@@ -26,6 +26,7 @@ class TopicListSerializer < ApplicationSerializer
def include_tags?
SiteSetting.tagging_enabled && SiteSetting.show_filter_by_tag
end
def tags
Tag.top_tags
end