Revert "DEV: Topic tracking state improvements (#12958)" (#13209)

This reverts commit 002c6763440c65bd6587dbe5b8e820b3713f406c.

Perf regression, we will redo it.
This commit is contained in:
Osama Sayegh
2021-05-31 10:47:42 +03:00
committed by GitHub
parent f3fdc7a6e8
commit b81b24dea2
14 changed files with 519 additions and 1480 deletions

View File

@ -608,9 +608,7 @@ class ApplicationController < ActionController::Base
def preload_current_user_data
store_preloaded("currentUser", MultiJson.dump(CurrentUserSerializer.new(current_user, scope: guardian, root: false)))
report = TopicTrackingState.report(current_user)
serializer = ActiveModel::ArraySerializer.new(
report, each_serializer: TopicTrackingStateSerializer, scope: guardian
)
serializer = ActiveModel::ArraySerializer.new(report, each_serializer: TopicTrackingStateSerializer)
store_preloaded("topicTrackingStates", MultiJson.dump(serializer))
end