WordPress.org

Make WordPress Core


Ignore:
Timestamp:
02/10/2020 07:55:51 PM (10 months ago)
Author:
SergeyBiryukov
Message:

Privacy: Rename wp_get_user_request_data() to wp_get_user_request() for clarity; deprecate the old function.

The function returns an instance of the WP_User_Request object itself, not its $request_data property.

Follow-up to [44606].

Props garrett-eclipse.
Fixes #46302.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-admin/includes/privacy-tools.php

    r47219 r47245  
    4242 *
    4343 * @param  int          $request_id Request ID.
    44  * @return int|WP_Error $result Request ID on success or WP_Error.
     44 * @return int|WP_Error $result     Request ID on success or WP_Error.
    4545 */
    4646function _wp_privacy_completed_request( $request_id ) {
     47    // Get the request.
    4748    $request_id = absint( $request_id );
    48     $request    = wp_get_user_request_data( $request_id );
     49    $request    = wp_get_user_request( $request_id );
    4950
    5051    if ( ! $request ) {
     
    289290    }
    290291
    291     // Get the request data.
    292     $request = wp_get_user_request_data( $request_id );
     292    // Get the request.
     293    $request = wp_get_user_request( $request_id );
    293294
    294295    if ( ! $request || 'export_personal_data' !== $request->action_name ) {
     
    502503 */
    503504function wp_privacy_send_personal_data_export_email( $request_id ) {
    504     // Get the request data.
    505     $request = wp_get_user_request_data( $request_id );
     505    // Get the request.
     506    $request = wp_get_user_request( $request_id );
    506507
    507508    if ( ! $request || 'export_personal_data' !== $request->action_name ) {
     
    672673    }
    673674
    674     // Get the request data.
    675     $request = wp_get_user_request_data( $request_id );
     675    // Get the request.
     676    $request = wp_get_user_request( $request_id );
    676677
    677678    if ( ! $request || 'export_personal_data' !== $request->action_name ) {
     
    816817    }
    817818
    818     $request = wp_get_user_request_data( $request_id );
     819    // Get the request.
     820    $request = wp_get_user_request( $request_id );
    819821
    820822    if ( ! $request || 'remove_personal_data' !== $request->action_name ) {
Note: See TracChangeset for help on using the changeset viewer.