Privacy: Check if the accumulated data in wp_privacy_process_personal_data_export_page()
is not empty.
This avoids an error on PHP 8 caused by passing an empty string to `array_merge()`, instead of an array. See #50913. git-svn-id: https://develop.svn.wordpress.org/trunk@49026 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
parent
6242c634ee
commit
e8b00da747
@ -767,7 +767,11 @@ function wp_privacy_process_personal_data_export_page( $response, $exporter_inde
|
||||
if ( 1 === $exporter_index && 1 === $page ) {
|
||||
update_post_meta( $request_id, '_export_data_raw', $export_data );
|
||||
} else {
|
||||
$export_data = get_post_meta( $request_id, '_export_data_raw', true );
|
||||
$accumulated_data = get_post_meta( $request_id, '_export_data_raw', true );
|
||||
|
||||
if ( $accumulated_data ) {
|
||||
$export_data = $accumulated_data;
|
||||
}
|
||||
}
|
||||
|
||||
// Now, merge the data from the exporter response into the data we have accumulated already.
|
||||
|
Loading…
Reference in New Issue
Block a user