Repository navigation
Comment REST API route: add support for filtering by multiple statuses. #9870
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
adamsilverstein
wants to merge
33
commits into
WordPress:trunk
Choose a base branch
from
adamsilverstein:add/comment-rest-api-types-support
base: trunk
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
Show all changes
33 commits
Select commit
Hold shift + click to select a range
82c76fa
Comments REST endpoint - support for multiple status values
adamsilverstein 1fc983f
Add tests for getting comments by status, statuses or ‘all’
adamsilverstein 4ee6fe8
spacing fixes for linter
adamsilverstein bdd5a6d
Use count
adamsilverstein b878d8b
Complete tests for status field
adamsilverstein f435d93
update wp-api-generated
adamsilverstein 7b22c39
Update tests/phpunit/tests/rest-api/rest-comments-controller.php
adamsilverstein 6225ae6
hello yoda my old friend
adamsilverstein f121b3e
API handles strings automatically when array type given
adamsilverstein 5fba5f6
Handle multiple status sanitization
adamsilverstein 1ee7a86
Add additional tests
adamsilverstein 3bf3121
Update src/wp-includes/rest-api/endpoints/class-wp-rest-comments-cont…
adamsilverstein f210ce5
Update tests/phpunit/tests/rest-api/rest-comments-controller.php
adamsilverstein faca069
Merge trunk into add/comment-rest-api-types-support
adamsilverstein 0426084
Fix comments status permission check for array values
adamsilverstein c4159ea
Consolidate and expand comment status query tests
adamsilverstein a2972fd
Update since tag to 7.1.0
adamsilverstein 4b93f1a
Merge branch 'trunk' into add/comment-rest-api-types-support
adamsilverstein d064fb8
Merge branch 'trunk' of https://github.com/WordPress/wordpress-develo…
westonruter 5217fd2
Narrow types on sanitize_comment_statuses() method
westonruter cd4496f
Tighten sanitize_comment_statuses() to return list<non-empty-lowercas…
westonruter c1c7823
Add typing to data_sanitize_comment_statuses
westonruter f44de34
Add native type hints to test class properties
westonruter b9b22de
Address PHPStan issues in tests
westonruter 9a34a07
Apply suggestions from code review
adamsilverstein f29b134
Cover comma-separated multi-status requests in the authorization test
adamsilverstein 6dd63d2
Preserve a literal '0' status when sanitizing the status parameter
adamsilverstein 79d5aa4
Merge trunk into add/comment-rest-api-types-support
adamsilverstein 303f021
Update @since for sanitize_comment_statuses() to 7.2.0
adamsilverstein 325b6e7
Merge trunk into add/comment-rest-api-types-support
adamsilverstein f18c8e4
REST API: Make the comments `status` default an array.
adamsilverstein 60db941
Merge remote-tracking branch 'origin/trunk' into pr9870-trunk-merge
adamsilverstein dffa629
Merge branch 'trunk' into add/comment-rest-api-types-support
adamsilverstein File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Some comments aren't visible on the classic Files Changed page.
There are no files selected for viewing
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
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
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
Oops, something went wrong.
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.
Uh oh!
There was an error while loading. Please reload this page.