General: In `wp_debug_backtrace_summary()`, check if `$call['args']` is defined to avoid a PHP notice.
Props paulschreiber. Fixes #31215. Built from https://develop.svn.wordpress.org/trunk@42824 git-svn-id: http://core.svn.wordpress.org/trunk@42654 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
ba7b8cd8a0
commit
8bab745586
|
@ -5410,7 +5410,8 @@ function wp_debug_backtrace_summary( $ignore_class = null, $skip_frames = 0, $pr
|
||||||
if ( in_array( $call['function'], array( 'do_action', 'apply_filters', 'do_action_ref_array', 'apply_filters_ref_array' ) ) ) {
|
if ( in_array( $call['function'], array( 'do_action', 'apply_filters', 'do_action_ref_array', 'apply_filters_ref_array' ) ) ) {
|
||||||
$caller[] = "{$call['function']}('{$call['args'][0]}')";
|
$caller[] = "{$call['function']}('{$call['args'][0]}')";
|
||||||
} elseif ( in_array( $call['function'], array( 'include', 'include_once', 'require', 'require_once' ) ) ) {
|
} elseif ( in_array( $call['function'], array( 'include', 'include_once', 'require', 'require_once' ) ) ) {
|
||||||
$caller[] = $call['function'] . "('" . str_replace( $truncate_paths, '', wp_normalize_path( $call['args'][0] ) ) . "')";
|
$filename = isset( $call['args'][0] ) ? $call['args'][0] : '';
|
||||||
|
$caller[] = $call['function'] . "('" . str_replace( $truncate_paths, '', wp_normalize_path( $filename ) ) . "')";
|
||||||
} else {
|
} else {
|
||||||
$caller[] = $call['function'];
|
$caller[] = $call['function'];
|
||||||
}
|
}
|
||||||
|
|
|
@ -4,7 +4,7 @@
|
||||||
*
|
*
|
||||||
* @global string $wp_version
|
* @global string $wp_version
|
||||||
*/
|
*/
|
||||||
$wp_version = '5.0-alpha-42823';
|
$wp_version = '5.0-alpha-42824';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 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.
|
||||||
|
|
Loading…
Reference in New Issue