mirror of
https://github.com/discourse/discourse.git
synced 2025-02-25 18:55:32 -06:00
FEATURE: Add user preference for title counter mode (#7364)
This commit is contained in:
@@ -43,7 +43,8 @@ class CurrentUserSerializer < BasicUserSerializer
|
||||
:hide_profile_and_presence,
|
||||
:groups,
|
||||
:second_factor_enabled,
|
||||
:ignored_users
|
||||
:ignored_users,
|
||||
:title_count_mode
|
||||
|
||||
def groups
|
||||
object.visible_groups.pluck(:id, :name).map { |id, name| { id: id, name: name.downcase } }
|
||||
@@ -89,6 +90,10 @@ class CurrentUserSerializer < BasicUserSerializer
|
||||
object.user_option.dynamic_favicon
|
||||
end
|
||||
|
||||
def title_count_mode
|
||||
object.user_option.title_count_mode
|
||||
end
|
||||
|
||||
def automatically_unpin_topics
|
||||
object.user_option.automatically_unpin_topics
|
||||
end
|
||||
|
@@ -24,7 +24,8 @@ class UserOptionSerializer < ApplicationSerializer
|
||||
:homepage_id,
|
||||
:hide_profile_and_presence,
|
||||
:text_size,
|
||||
:text_size_seq
|
||||
:text_size_seq,
|
||||
:title_count_mode
|
||||
|
||||
def auto_track_topics_after_msecs
|
||||
object.auto_track_topics_after_msecs || SiteSetting.default_other_auto_track_topics_after_msecs
|
||||
|
Reference in New Issue
Block a user