BP_REST_Media_Details_Endpoint::get_items( WP_REST_Request $request )
Retrieve Media details.
Description
Parameters
- $request
-
(Required) Full details about the request.
Return
(WP_REST_Response) | WP_Error
Source
File: bp-media/classes/class-bp-rest-media-details-endpoint.php
public function get_items( $request ) { $retval = array(); $retval['tabs'] = $this->get_media_tabs(); $retval['privacy'] = $this->get_media_privacy(); $response = rest_ensure_response( $retval ); /** * Fires after a list of medias details is fetched via the REST API. * * @since 0.1.0 * * @param WP_REST_Response $response The response data. * @param WP_REST_Request $request The request sent to the API. */ do_action( 'bp_rest_media_details_get_items', $response, $request ); return $response; }
Changelog
Version | Description |
---|---|
0.1.0 | Introduced. |
Questions?
We're always happy to help with code or other questions you might have! Search our developer docs, contact support, or connect with our sales team.