#3128 closed enhancement (fixed)
Filter the array of non-public statuses in bbp_update_topic_reply_count_hidden()
Reported by: |
|
Owned by: |
|
---|---|---|---|
Milestone: | 2.6 | Priority: | normal |
Severity: | normal | Version: | |
Component: | Component - Topics | Keywords: | commit |
Cc: |
Description
In bbp_update_topic_reply_count_hidden(), the list of non-public statuses is limited to three existing statuses: trash
, spam
, pending
.
WordPress.org forums have an archived
status, added in #meta1963 as a way to hide posts from public view while keeping them for future reference (e.g. to check the history of a particular user). "Trash" was not suitable for that, as trashed posts are auto-deleted after 30 days. "Pending" was not suitable either, as already reviewed posts should not be moved back to moderation queue.
bbp_update_topic_reply_count_hidden()
should have a filter on $statuses
to allow for specifying additional non-public statuses.
At a glance, the following functions would benefit from a similar change:
bbp_get_all_child_ids()
bbp_update_forum_topic_count_hidden()
bbp_admin_repair_topic_hidden_reply_count()
I guess there should be a filterable
bbp_get_hidden_statuses()
function that could be used in all of those instances.