[wp-meta] [Making WordPress.org] #2504: Forums: Replies from archived topics are still displayed in user profiles
Making WordPress.org
noreply at wordpress.org
Sun Nov 24 05:45:55 UTC 2019
#2504: Forums: Replies from archived topics are still displayed in user profiles
----------------------------+---------------------
Reporter: SergeyBiryukov | Owner: (none)
Type: defect | Status: new
Priority: high | Milestone: Q1
Component: Support Forums | Resolution:
Keywords: |
----------------------------+---------------------
Comment (by johnjamesjacoby):
See: `bbp_trash_topic_replies()` and `bbp_untrash_topic_replies()`
When a Topic has some action taken on it, some other action needs to run
on the children Replies.
Unfortunately, you cannot simply blindly take action on all of them,
because some of them may already be trashed, and you don't want untrashing
something to accidentally bring things back from the dead.
See the `_bbp_pre_trashed_replies` Topic meta key, as an example of this
juggle. It makes sure that when a Topic is untrashed, that previously
trashed Replies do not suddenly also become untrashed.
(The same happens when marking a Topic as Spam.)
My recommendation is to mirror this behavior for Topic Archives, and mark
the replies as `archived` as well. This may require a bit of finesse,
since Topics generally expect their replies to either be "public" or "non-
public" by default, and Archived kinda walks the line.
--
Ticket URL: <https://meta.trac.wordpress.org/ticket/2504#comment:11>
Making WordPress.org <https://meta.trac.wordpress.org/>
Making WordPress.org
More information about the wp-meta
mailing list