There is a flatten
function found on line 76 of libraries/Demandbase.php, which seems to be throwing two warnings in our error logs:
“Invalid argument supplied for foreach()…” and “Cannot modify header information…”
In order to suppress the errors, I wrapped the function’s foreach()
loop in a if(is_array($array))
conditional, which seems to have resolved the issue.
Is there any harm in leaving this conditional check here? Should it be added directly to the plugin?
Environment Notes