From 13dee8f174075708eb0b5acf2cb3ad59ec2a88e9 Mon Sep 17 00:00:00 2001 From: Sergey Biryukov Date: Mon, 6 Jul 2020 00:32:15 +0000 Subject: [PATCH] Privacy: Simplify the logic for updating the meta values for personal data export requests from absolute to relative paths. Follow-up to [48127]. See #44038. git-svn-id: https://develop.svn.wordpress.org/trunk@48330 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-admin/includes/privacy-tools.php | 54 +++++++------------ ...wpPrivacyProcessPersonalDataExportPage.php | 10 ++-- .../wpPrivacySendPersonalDataExportEmail.php | 10 ++-- 3 files changed, 30 insertions(+), 44 deletions(-) diff --git a/src/wp-admin/includes/privacy-tools.php b/src/wp-admin/includes/privacy-tools.php index 1edbcae495..d9480481f2 100644 --- a/src/wp-admin/includes/privacy-tools.php +++ b/src/wp-admin/includes/privacy-tools.php @@ -277,7 +277,7 @@ function wp_privacy_generate_personal_data_export_group_html( $group_data, $grou $group_html .= ''; } - if ( 1 < $groups_count ) { + if ( $groups_count > 1 ) { $group_html .= '
'; $group_html .= ' ' . esc_html__( 'Return to top' ) . ''; $group_html .= '
'; @@ -433,7 +433,7 @@ function wp_privacy_generate_personal_data_export_file( $request_id ) { fwrite( $file, '

' . esc_html__( 'Personal Data Export' ) . '

' ); // Create TOC. - if ( 1 < $groups_count ) { + if ( $groups_count > 1 ) { fwrite( $file, '
' ); fwrite( $file, '

' . esc_html__( 'Table of Contents' ) . '

' ); fwrite( $file, '