Details
-
Bug
-
Resolution: Fixed
-
Medium
-
4.4.0, 4.5.0alpha
-
None
Description
Around line 1746 in function appendDebugNodes( &$root, &$resourceData ), at the test:
if ( isset( $root[1][0][2] ) && strpos( $root[1][0][2], '<!DOCTYPE' ) === 0 ) return;
$root[1][0][2] is not all the time a string, and it troughs a warning when it's not.
In my case, I have a template beginning with:
{ezscript_require( 'dmv_form.js' )}
As a result $root[1][0][2] is an array here (the array decdecomposition of this ez template code I guess)
=> a fix would be to check the type of $root[1][0][2], or hide notice with @strpos
Should be something like this:
if ( isset( $root[1][0][2] ) && gettype( $root[1][0][2] ) == "string" && strpos( $root[1][0][2], '<!DOCTYPE' ) === 0 ) return;