💦 FULL SET: Changeset/ - Complete Album!

Changeset 49090


Ignore:
Timestamp:
10/04/2020 03:21:38 AM (5 years ago)
Author:
SergeyBiryukov
Message:

Privacy: Improve clarity of privacy error strings.

Primarily this adds "user privacy" to the strings for privacy requests, so they are more easily distinguished from other system actions within logs.

Props garrett-eclipse, carike, birgire.
Fixes #51351.

Location:
trunk
Files:
7 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-admin/erase-personal-data.php

    r48468 r49090  
    1111
    1212if ( ! current_user_can( 'erase_others_personal_data' ) || ! current_user_can( 'delete_users' ) ) {
    13     wp_die( __( 'Sorry, you are not allowed to erase data on this site.' ) );
     13    wp_die( __( 'Sorry, you are not allowed to erase personal data on this site.' ) );
    1414}
    1515
  • trunk/src/wp-admin/includes/privacy-tools.php

    r49026 r49090  
    2121
    2222    if ( ! $request || 'user_request' !== $request->post_type ) {
    23         return new WP_Error( 'privacy_request_error', __( 'Invalid request.' ) );
     23        return new WP_Error( 'privacy_request_error', __( 'Invalid user privacy request.' ) );
    2424    }
    2525
     
    2929        return $result;
    3030    } elseif ( ! $result ) {
    31         return new WP_Error( 'privacy_request_error', __( 'Unable to initiate confirmation request.' ) );
     31        return new WP_Error( 'privacy_request_error', __( 'Unable to initiate user privacy confirmation request.' ) );
    3232    }
    3333
     
    5050
    5151    if ( ! $request ) {
    52         return new WP_Error( 'privacy_request_error', __( 'Invalid request.' ) );
     52        return new WP_Error( 'privacy_request_error', __( 'Invalid user privacy request.' ) );
    5353    }
    5454
     
    105105                        'action_type',
    106106                        'action_type',
    107                         __( 'Invalid action.' ),
     107                        __( 'Invalid user privacy action.' ),
    108108                        'error'
    109109                    );
     
    117117                        'action_type',
    118118                        'action_type',
    119                         __( 'Invalid action.' ),
     119                        __( 'Invalid user privacy action.' ),
    120120                        'error'
    121121                    );
     
    298298function wp_privacy_generate_personal_data_export_file( $request_id ) {
    299299    if ( ! class_exists( 'ZipArchive' ) ) {
    300         wp_send_json_error( __( 'Unable to generate export file. ZipArchive not available.' ) );
     300        wp_send_json_error( __( 'Unable to generate user privacy export file. ZipArchive not available.' ) );
    301301    }
    302302
     
    305305
    306306    if ( ! $request || 'export_personal_data' !== $request->action_name ) {
    307         wp_send_json_error( __( 'Invalid request ID when generating export file.' ) );
     307        wp_send_json_error( __( 'Invalid request ID when generating user privacy export file.' ) );
    308308    }
    309309