6bfb976577
Previously, when getting posts from the API with `sticky=true`, if there were no sticky posts set, the query would return all posts as if the `sticky` argument was not set. In this situation, the query should return an empty array instead. A `sticky=true` query that should return an empty array (in the previous situation, or with `include` and no intersecting post IDs) was also broken in that it would query the post with ID 1. Finally, this commit significantly improves test coverage for the `sticky` filter argument, including direct testing of the `WHERE` clauses generated by `WP_Query`. Merge of [40037] and [40122] to the 4.7 branch. Props ryelle, jnylen0. See #39079. Fixes #39947. git-svn-id: https://develop.svn.wordpress.org/branches/4.7@40136 602fd350-edb4-49c9-b593-d223f7449a82 |
||
---|---|---|
src | ||
tests | ||
tools/i18n | ||
.editorconfig | ||
.gitignore | ||
.jshintrc | ||
.travis.yml | ||
Gruntfile.js | ||
npm-shrinkwrap.json | ||
package.json | ||
phpunit.xml.dist | ||
wp-cli.yml | ||
wp-config-sample.php | ||
wp-tests-config-sample.php |