- Timestamp:
- 07/22/2022 01:58:46 PM (3 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-includes/rest-api/endpoints/class-wp-rest-plugins-controller.php
r53724 r53760 577 577 */ 578 578 public function prepare_item_for_response( $item, $request ) { 579 $fields = $this->get_fields_for_response( $request ); 580 579 581 $item = _get_plugin_data_markup_translate( $item['_file'], $item, false ); 580 582 $marked = _get_plugin_data_markup_translate( $item['_file'], $item, true ); … … 601 603 602 604 $response = new WP_REST_Response( $data ); 603 $response->add_links( $this->prepare_links( $item ) ); 605 606 if ( rest_is_field_included( '_links', $fields ) || rest_is_field_included( '_embedded', $fields ) ) { 607 $response->add_links( $this->prepare_links( $item ) ); 608 } 604 609 605 610 /**
Note: See TracChangeset
for help on using the changeset viewer.