Make WordPress Core

Changeset 45246


Ignore:
Timestamp:
04/18/2019 04:25:05 PM (6 years ago)
Author:
ocean90
Message:

Site Health: Fix debug data with nested fields for copying.

  • Use $debug_data instead of $field['value'] to retrieve the debug data.
  • Rename inner variables to avoid overriding the output variable.

Props Clorith, ocean90.
See #46573.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-admin/includes/class-wp-debug-data.php

    r45239 r45246  
    10601060                    $value = '';
    10611061
    1062                     foreach ( $field['value'] as $name => $value ) {
    1063                         $value .= sprintf( "\n\t%s: %s", $name, $value );
     1062                    foreach ( $debug_data as $sub_field_name => $sub_field_value ) {
     1063                        $value .= sprintf( "\n\t%s: %s", $sub_field_name, $sub_field_value );
    10641064                    }
    10651065                } elseif ( is_bool( $debug_data ) ) {
Note: See TracChangeset for help on using the changeset viewer.