discourse/config
Alan Guo Xiang Tan e3977f84a3
FIX: Incorrect topic tracking state count when a new category is created (#20506)
What is the problem?

We have a hidden site setting `show_category_definitions_in_topic_lists`
which is set to false by default. What this means is that category
definition topics are not shown in the topic list by default. Only the
category definition topic for the category being viewed will be shown.
However, we have a bug where we would show that a category has new
topics when a new child category along with its category definition
topic is created even though the topic list does not list the child
category's category definition topic.

What is the fix here?

This commit fixes the problem by shipping down an additional
`is_category_topic` attribute in `TopicTrackingStateItemSerializer` when
the `show_category_definitions_in_topic_lists` site setting has been set
to false. With the new attribute, we can then exclude counting child
categories' category definition topics when counting new and unread
counts for a category.
2023-03-06 10:13:10 +08:00
..
cloud/cloud66 DEV: Apply syntax_tree formatting to config/* 2023-01-09 11:13:29 +00:00
environments FEATURE: log to STDOUT using Rails 5 env var (#18880) 2023-03-01 07:06:14 +08:00
initializers DEV: Use internal __autoloads for zeitwork reload check (#20260) 2023-02-13 16:26:40 +10:00
locales DEV: Experimental /filter route to filter through topics (#20494) 2023-03-03 09:46:21 +08:00
application.rb Bump minimum Ruby version to 3.1 (#19848) 2023-01-12 13:52:50 +00:00
boot.rb DEV: Apply syntax_tree formatting to config/* 2023-01-09 11:13:29 +00:00
cdn.yml.sample
database.yml Revert "DEV: Improve multisite db scripts in dev (#17337)" (#17801) 2022-08-04 16:15:06 -05:00
deploy.rb.sample
dev_defaults.yml DEV: Fix typos and outdated comments (#16614) 2022-05-04 14:12:18 +08:00
discourse_defaults.conf FIX: allow changing default DNS query timeout of 2s via GlobalSetting (#20383) 2023-02-21 09:54:29 +11:00
discourse.config.sample
discourse.pill.sample
environment.rb DEV: Apply syntax_tree formatting to config/* 2023-01-09 11:13:29 +00:00
logrotate.conf
multisite.yml.production-sample DEV: Remove db_id from sample multisite config. 2020-05-29 10:48:29 +08:00
nginx.global.conf
nginx.sample.conf FIX: Update nginx config for v1.23 (#19651) 2022-12-30 12:35:26 +00:00
projections.json DEV: Use .hbr for raw template file extension (#8883) 2020-02-11 13:38:12 -06:00
puma.rb DEV: Apply syntax_tree formatting to config/* 2023-01-09 11:13:29 +00:00
routes.rb DEV: Experimental /filter route to filter through topics (#20494) 2023-03-03 09:46:21 +08:00
sidekiq.yml
site_settings.yml FIX: Incorrect topic tracking state count when a new category is created (#20506) 2023-03-06 10:13:10 +08:00
spring.rb DEV: Apply syntax_tree formatting to config/* 2023-01-09 11:13:29 +00:00
thin.yml.sample
unicorn_launcher
unicorn_upstart.conf
unicorn.conf.rb DEV: Revert syntax-tree line change in unicorn.conf.rb listen (#19874) 2023-01-16 13:17:23 +10:00