A platform for community discussion. Free, open, simple.
DEV: Don't eager load tags when tagging is not enabled.
Alan Guo Xiang Tan7719453fb73d
diff --git a/lib/topic_query.rb b/lib/topic_query.rbindex d09701fae7a..d296fc8f480 100644--- a/lib/topic_query.rb+++ b/lib/topic_query.rb@@ -586,7 +586,8 @@ class TopicQueryoptions = @optionsoptions.reverse_merge!(per_page: per_page_setting)- result = Topic.includes(:tags, :allowed_users)+ result = Topic.includes(:allowed_users)+ result = result.includes(:tags) if SiteSetting.tagging_enabledif type == :groupresult = result.joins(