Skip to content

Only feature publicly queryable posts - #3971

Merged
pfefferle merged 3 commits into
trunkfrom
fix/featured-password
Oct 27, 2026
Merged

pfefferle merged 3 commits into
trunkfrom
fix/featured-password

Conversation

@pfefferle

Copy link
Copy Markdown
Member

Fixes #

Proposed changes:

  • The featured collection queried sticky posts and only left out posts with a content visibility set. A password-protected sticky post, or one whose post type no longer supports ActivityPub, was still listed and counted (its content was already redacted to a Tombstone).
  • The query result now goes through is_post_publicly_queryable(), the same check the router and the other controllers use. The meta_query stays as a cheap pre-filter.
  • totalItems uses count() directly, since $posts is always a list now.

Other information:

  • Have you written new tests for your changes, if applicable?

Testing instructions:

  • vendor/bin/phpunit --filter test_get_featured_skips_password_protected_posts
  • Make two posts sticky, protect one with a password, and check that /wp-json/activitypub/1.0/actors/<id>/collections/featured only lists the other one.

Changelog entry

  • Automatically create a changelog entry from the details below.
Changelog Entry Details

Significance

  • Patch
  • Minor
  • Major

Type

  • Added - for new features
  • Changed - for changes in existing functionality
  • Deprecated - for soon-to-be removed features
  • Removed - for now removed features
  • Fixed - for any bug fixes
  • Security - in case of vulnerabilities

Message

@pfefferle
pfefferle merged commit 0c82ba4 into trunk Oct 27, 2026
12 checks passed
@pfefferle
pfefferle deleted the fix/featured-password branch October 27, 2026 16:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant