Repository navigation
Keep unpublished related posts when saving from the editor - #145
Merged
Merged
Conversation
- load related items in the editor store with post_status=any - when replacing related items, keep the related posts the user cannot list, using the same query and readability restriction as the related list, and leave them out of the response - share the related posts query args, readability restriction, and filtered query between the list and the replace paths - rebuild the editor bundles
Member
Author
Member
Author
|
@rickalee @fabiankaegy can any of you test this update so we can "close" and release version 2.0.0? |
rickalee
approved these changes
Nov 19, 2026
rickalee
left a comment
Contributor
There was a problem hiding this comment.
@s3rgiosan Tested against two large codebases and custom REST endpoints. Approved.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Saving a post in the editor keeps its relationships to draft, pending, scheduled, private, and trashed posts.
post_status=any.POST /content-connect/v2/post/{post_id}/relatedkeeps related posts that the related list hides from the current user. It finds them with the same query and readability restriction as the list, including thetenup_content_connect_related_posts_readable_wherefilter. Kept posts are sorted last and left out of the response.Base branch is
fix/related-route-post-status(#143), which this builds on.How to test
npm run test:phpruns the new cases intests/php/API/V2/Post/Route/RelatedEntitiesTest.php.Changelog Entry