Changeset 51786 for trunk/src/wp-includes/rest-api/endpoints/class-wp-rest-pattern-directory-controller.php
- Timestamp:
- 09/09/2021 06:35:34 PM (4 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-includes/rest-api/endpoints/class-wp-rest-pattern-directory-controller.php
r51289 r51786 200 200 * 201 201 * @since 5.8.0 202 * 203 * @param object $raw_pattern A pattern from api.wordpress.org, before any changes. 204 * @param WP_REST_Request $request Request object. 202 * @since 5.9.0 Renamed `$raw_pattern` to `$item` to match parent class for PHP 8 named parameter support. 203 * 204 * @param object $item Raw pattern from api.wordpress.org, before any changes. 205 * @param WP_REST_Request $request Request object. 205 206 * @return WP_REST_Response 206 207 */ 207 public function prepare_item_for_response( $raw_pattern, $request ) { 208 public function prepare_item_for_response( $item, $request ) { 209 // Restores the more descriptive, specific name for use within this method. 210 $raw_pattern = $item; 208 211 $prepared_pattern = array( 209 212 'id' => absint( $raw_pattern->id ),
Note: See TracChangeset
for help on using the changeset viewer.