diff options
author | Eugen Rochko <eugen@zeonfederated.com> | 2019-08-06 17:57:52 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-08-06 17:57:52 +0200 |
commit | 9072fe5ab6464cc9c7a871d388464c7afcf41cd0 (patch) | |
tree | b3b379a4eeebc56825a6374f854e73b35678da6c /app/serializers | |
parent | 82d2069c75071138f582503c39b0996cc4cdff11 (diff) |
Add trends UI with admin and user settings (#11502)
Diffstat (limited to 'app/serializers')
-rw-r--r-- | app/serializers/initial_state_serializer.rb | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/app/serializers/initial_state_serializer.rb b/app/serializers/initial_state_serializer.rb index 7e5d3eda9..c92c5e606 100644 --- a/app/serializers/initial_state_serializer.rb +++ b/app/serializers/initial_state_serializer.rb @@ -20,6 +20,7 @@ class InitialStateSerializer < ActiveModel::Serializer invites_enabled: Setting.min_invite_role == 'user', mascot: instance_presenter.mascot&.file&.url, profile_directory: Setting.profile_directory, + trends: Setting.trends, } if object.current_account @@ -35,6 +36,7 @@ class InitialStateSerializer < ActiveModel::Serializer store[:use_blurhash] = object.current_account.user.setting_use_blurhash store[:use_pending_items] = object.current_account.user.setting_use_pending_items store[:is_staff] = object.current_account.user.staff? + store[:trends] = Setting.trends && object.current_account.user.setting_trends end store |