/**
* Checks if a given request has access to update the current user.
*
* @since 4.7.0
*
* @param WP_REST_Request $request Full details about the request.
* @return true|WP_Error True if the request has access to update the item, WP_Error object otherwise.
*/
public function update_current_item_permissions_check( $request ) { $request['id'
] =
get_current_user_id();
return $this->
update_item_permissions_check( $request );
} /**
* Updates the current user.
*
* @since 4.7.0
*
* @param WP_REST_Request $request Full details about the request.
* @return WP_REST_Response|WP_Error Response object on success, or WP_Error object on failure.
*/
public function update_current_item( $request ) {