From 17728c521520ea4b8da644b7657c1594d59fc9cb Mon Sep 17 00:00:00 2001 From: Sergey Biryukov Date: Sat, 6 Apr 2019 15:35:44 +0000 Subject: [PATCH] Site Health: Restore backticks in "Copy to clipboard" functionality, accidentally removed in [45044]. The backticks ensure that the data is formatted accordingly on pasting whenever possible. Props Clorith. Fixes #46809. git-svn-id: https://develop.svn.wordpress.org/trunk@45119 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-admin/includes/class-wp-debug-data.php | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/wp-admin/includes/class-wp-debug-data.php b/src/wp-admin/includes/class-wp-debug-data.php index 850ae9a860..e646cad3e4 100644 --- a/src/wp-admin/includes/class-wp-debug-data.php +++ b/src/wp-admin/includes/class-wp-debug-data.php @@ -902,7 +902,7 @@ class WP_Debug_Data { * @return string The formatted data. */ public static function format( $info_array, $type = 'text' ) { - $return = ''; + $return = "`\n"; foreach ( $info_array as $section => $details ) { // Skip this section if there are no fields, or the section has been declared as private. @@ -943,6 +943,8 @@ class WP_Debug_Data { $return .= "\n"; } + $return .= "`"; + return $return; }