- Timestamp:
- 11/11/2019 02:41:15 AM (5 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-includes/rest-api/endpoints/class-wp-rest-controller.php
r46586 r46696 55 55 * 56 56 * @param WP_REST_Request $request Full data about the request. 57 * @return WP_Error|boolTrue if the request has read access, WP_Error object otherwise.57 * @return true|WP_Error True if the request has read access, WP_Error object otherwise. 58 58 */ 59 59 public function get_items_permissions_check( $request ) { … … 68 68 * 69 69 * @param WP_REST_Request $request Full data about the request. 70 * @return WP_ Error|WP_REST_ResponseResponse object on success, or WP_Error object on failure.70 * @return WP_REST_Response|WP_Error Response object on success, or WP_Error object on failure. 71 71 */ 72 72 public function get_items( $request ) { … … 81 81 * 82 82 * @param WP_REST_Request $request Full data about the request. 83 * @return WP_Error|boolTrue if the request has read access for the item, WP_Error object otherwise.83 * @return true|WP_Error True if the request has read access for the item, WP_Error object otherwise. 84 84 */ 85 85 public function get_item_permissions_check( $request ) { … … 94 94 * 95 95 * @param WP_REST_Request $request Full data about the request. 96 * @return WP_ Error|WP_REST_ResponseResponse object on success, or WP_Error object on failure.96 * @return WP_REST_Response|WP_Error Response object on success, or WP_Error object on failure. 97 97 */ 98 98 public function get_item( $request ) { … … 107 107 * 108 108 * @param WP_REST_Request $request Full data about the request. 109 * @return WP_Error|boolTrue if the request has access to create items, WP_Error object otherwise.109 * @return true|WP_Error True if the request has access to create items, WP_Error object otherwise. 110 110 */ 111 111 public function create_item_permissions_check( $request ) { … … 120 120 * 121 121 * @param WP_REST_Request $request Full data about the request. 122 * @return WP_ Error|WP_REST_ResponseResponse object on success, or WP_Error object on failure.122 * @return WP_REST_Response|WP_Error Response object on success, or WP_Error object on failure. 123 123 */ 124 124 public function create_item( $request ) { … … 133 133 * 134 134 * @param WP_REST_Request $request Full data about the request. 135 * @return WP_Error|boolTrue if the request has access to update the item, WP_Error object otherwise.135 * @return true|WP_Error True if the request has access to update the item, WP_Error object otherwise. 136 136 */ 137 137 public function update_item_permissions_check( $request ) { … … 146 146 * 147 147 * @param WP_REST_Request $request Full data about the request. 148 * @return WP_ Error|WP_REST_ResponseResponse object on success, or WP_Error object on failure.148 * @return WP_REST_Response|WP_Error Response object on success, or WP_Error object on failure. 149 149 */ 150 150 public function update_item( $request ) { … … 159 159 * 160 160 * @param WP_REST_Request $request Full data about the request. 161 * @return WP_Error|boolTrue if the request has access to delete the item, WP_Error object otherwise.161 * @return true|WP_Error True if the request has access to delete the item, WP_Error object otherwise. 162 162 */ 163 163 public function delete_item_permissions_check( $request ) { … … 172 172 * 173 173 * @param WP_REST_Request $request Full data about the request. 174 * @return WP_ Error|WP_REST_ResponseResponse object on success, or WP_Error object on failure.174 * @return WP_REST_Response|WP_Error Response object on success, or WP_Error object on failure. 175 175 */ 176 176 public function delete_item( $request ) { … … 185 185 * 186 186 * @param WP_REST_Request $request Request object. 187 * @return WP_Error|objectThe prepared item, or WP_Error object on failure.187 * @return object|WP_Error The prepared item, or WP_Error object on failure. 188 188 */ 189 189 protected function prepare_item_for_database( $request ) { … … 199 199 * @param mixed $item WordPress representation of the item. 200 200 * @param WP_REST_Request $request Request object. 201 * @return WP_ Error|WP_REST_ResponseResponse object on success, or WP_Error object on failure.201 * @return WP_REST_Response|WP_Error Response object on success, or WP_Error object on failure. 202 202 */ 203 203 public function prepare_item_for_response( $item, $request ) {
Note: See TracChangeset
for help on using the changeset viewer.