Privacy: Fix a further inconsistency of site name and URL usage in notification emails.

This is a follow-up to [43388].

Props desrosj.
Fixes #44396.

Built from https://develop.svn.wordpress.org/trunk@43435


git-svn-id: http://core.svn.wordpress.org/trunk@43262 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
Felix Arntz 2018-07-08 13:55:28 +00:00
parent 60252611be
commit 9768bde3c4
2 changed files with 5 additions and 5 deletions

View File

@ -2236,20 +2236,20 @@ All at ###SITENAME###
$email_address = $request->email; $email_address = $request->email;
$export_file_url = get_post_meta( $request_id, '_export_file_url', true ); $export_file_url = get_post_meta( $request_id, '_export_file_url', true );
$site_name = is_multisite() ? get_site_option( 'site_name' ) : get_option( 'blogname' ); $site_name = wp_specialchars_decode( get_option( 'blogname' ), ENT_QUOTES );
$site_url = network_home_url(); $site_url = home_url();
$content = str_replace( '###EXPIRATION###', $expiration_date, $content ); $content = str_replace( '###EXPIRATION###', $expiration_date, $content );
$content = str_replace( '###LINK###', esc_url_raw( $export_file_url ), $content ); $content = str_replace( '###LINK###', esc_url_raw( $export_file_url ), $content );
$content = str_replace( '###EMAIL###', $email_address, $content ); $content = str_replace( '###EMAIL###', $email_address, $content );
$content = str_replace( '###SITENAME###', wp_specialchars_decode( $site_name, ENT_QUOTES ), $content ); $content = str_replace( '###SITENAME###', $site_name, $content );
$content = str_replace( '###SITEURL###', esc_url_raw( $site_url ), $content ); $content = str_replace( '###SITEURL###', esc_url_raw( $site_url ), $content );
$mail_success = wp_mail( $mail_success = wp_mail(
$email_address, $email_address,
sprintf( sprintf(
__( '[%s] Personal Data Export' ), __( '[%s] Personal Data Export' ),
wp_specialchars_decode( get_option( 'blogname' ), ENT_QUOTES ) $site_name
), ),
$content $content
); );

View File

@ -4,7 +4,7 @@
* *
* @global string $wp_version * @global string $wp_version
*/ */
$wp_version = '5.0-alpha-43434'; $wp_version = '5.0-alpha-43435';
/** /**
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema. * Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.