- Timestamp:
- 02/10/2025 10:21:51 PM (3 months ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-includes/rest-api/endpoints/class-wp-rest-posts-controller.php
r59630 r59801 248 248 'exclude' => 'post__not_in', 249 249 'include' => 'post__in', 250 'ignore_sticky' => 'ignore_sticky_posts', 250 251 'menu_order' => 'menu_order', 251 252 'offset' => 'offset', … … 336 337 $args['post__not_in'] = array_merge( $args['post__not_in'], $sticky_posts ); 337 338 } 339 } 340 341 /* 342 * Honor the original REST API `post__in` behavior. Don't prepend sticky posts 343 * when `post__in` has been specified. 344 */ 345 if ( ! empty( $args['post__in'] ) ) { 346 unset( $args['ignore_sticky_posts'] ); 338 347 } 339 348 … … 3046 3055 'type' => 'boolean', 3047 3056 ); 3057 3058 $query_params['ignore_sticky'] = array( 3059 'description' => __( 'Whether to ignore sticky posts or not.' ), 3060 'type' => 'boolean', 3061 'default' => false, 3062 ); 3048 3063 } 3049 3064
Note: See TracChangeset
for help on using the changeset viewer.