WordPress.org

Make WordPress Core

Changeset 43233


Ignore:
Timestamp:
05/10/2018 09:04:21 PM (3 years ago)
Author:
SergeyBiryukov
Message:

Privacy: Update request confirmation notice text for clarity.

Props desrosj, melchoyce, garrett-eclipse.
Merges [43232] to the 4.9 branch.
Fixes #43970.

Location:
branches/4.9
Files:
5 edited

Legend:

Unmodified
Added
Removed
  • branches/4.9

  • branches/4.9/src/wp-admin/css/login.css

    r43124 r43233  
    5050
    5151.login .message,
     52.login .success,
    5253.login #login_error {
    5354    border-left: 4px solid #00a0d2;
     
    5758    background-color: #fff;
    5859    box-shadow: 0 1px 1px 0 rgba(0,0,0,0.1);
     60}
     61
     62.login .success {
     63    border-left-color: #46b450;
    5964}
    6065
  • branches/4.9/src/wp-includes/default-filters.php

    r43225 r43233  
    324324add_action( 'user_request_action_confirmed', '_wp_privacy_account_request_confirmed' );
    325325add_action( 'user_request_action_confirmed', '_wp_privacy_send_request_confirmation_notification', 12 ); // After request marked as completed.
    326 add_filter( 'user_request_action_confirmed_message', '_wp_privacy_account_request_confirmed_message', 10, 2 );
    327326add_filter( 'wp_privacy_personal_data_exporters', 'wp_register_comment_personal_data_exporter' );
    328327add_filter( 'wp_privacy_personal_data_exporters', 'wp_register_media_personal_data_exporter' );
  • branches/4.9/src/wp-includes/user.php

    r43231 r43233  
    31093109 * @access private
    31103110 *
     3111 * @param int $request_id The request ID being confirmed.
    31113112 * @return string $message The confirmation message.
    31123113 */
    3113 function _wp_privacy_account_request_confirmed_message( $message, $request_id ) {
     3114function _wp_privacy_account_request_confirmed_message( $request_id ) {
    31143115    $request = wp_get_user_request_data( $request_id );
    31153116
     3117    $message = '<p class="success">' . __( 'Action has been confirmed.' ) . '</p>';
     3118    $message .= '<p>' . __( 'The site administrator has been notified and will fulfill your request as soon as possible.' ) . '</p>';
     3119
    31163120    if ( $request && in_array( $request->action_name, _wp_privacy_action_request_types(), true ) ) {
    3117         $message  = '<p class="message">' . __( 'Action has been confirmed.' ) . '</p>';
    3118         $message .= __( 'The site administrator has been notified and will fulfill your request as soon as possible.' );
    3119     }
     3121        if ( 'export_personal_data' === $request->action_name ) {
     3122            $message = '<p class="success">' . __( 'Thanks for confirming your export request.' ) . '</p>';
     3123            $message .= '<p>' . __( 'The site administrator has been notified. You will receive a link to download your export via email when they fulfill your request.' ) . '</p>';
     3124        } elseif ( 'remove_personal_data' === $request->action_name ) {
     3125            $message = '<p class="success">' . __( 'Thanks for confirming your erasure request.' ) . '</p>';
     3126            $message .= '<p>' . __( 'The site administrator has been notified. You will receive an email confirmation when they erase your data.' ) . '</p>';
     3127        }
     3128    }
     3129
     3130    /**
     3131     * Filters the message displayed to a user when they confirm a data request.
     3132     *
     3133     * @since 4.9.6
     3134     *
     3135     * @param string $message    The message to the user.
     3136     * @param int    $request_id The ID of the request being confirmed.
     3137     */
     3138    $message = apply_filters( 'user_request_action_confirmed_message', $message, $request_id );
    31203139
    31213140    return $message;
  • branches/4.9/src/wp-login.php

    r43124 r43233  
    871871    do_action( 'user_request_action_confirmed', $request_id );
    872872
    873     $message = apply_filters( 'user_request_action_confirmed_message', '<p class="message">' . __( 'Action has been confirmed.' ) . '</p>', $request_id );
     873    $message = _wp_privacy_account_request_confirmed_message( $request_id );
    874874
    875875    login_header( __( 'User action confirmed.' ), $message );
Note: See TracChangeset for help on using the changeset viewer.