[VarDumper] fixes
This commit is contained in:
parent
78f028cc75
commit
d7238c9d96
@ -45,7 +45,7 @@ class ResourceCaster
|
|||||||
|
|
||||||
public static function castStreamContext($stream, array $a, Stub $stub, $isNested)
|
public static function castStreamContext($stream, array $a, Stub $stub, $isNested)
|
||||||
{
|
{
|
||||||
return stream_context_get_params($stream);
|
return @stream_context_get_params($stream) ?: $a;
|
||||||
}
|
}
|
||||||
|
|
||||||
public static function castGd($gd, array $a, Stub $stub, $isNested)
|
public static function castGd($gd, array $a, Stub $stub, $isNested)
|
||||||
|
@ -86,7 +86,7 @@ class SplCaster
|
|||||||
$storage = array();
|
$storage = array();
|
||||||
unset($a[Caster::PREFIX_DYNAMIC."\0gcdata"]); // Don't hit https://bugs.php.net/65967
|
unset($a[Caster::PREFIX_DYNAMIC."\0gcdata"]); // Don't hit https://bugs.php.net/65967
|
||||||
|
|
||||||
foreach ($c as $obj) {
|
foreach (clone $c as $obj) {
|
||||||
$storage[spl_object_hash($obj)] = array(
|
$storage[spl_object_hash($obj)] = array(
|
||||||
'object' => $obj,
|
'object' => $obj,
|
||||||
'info' => $c->getInfo(),
|
'info' => $c->getInfo(),
|
||||||
|
Reference in New Issue
Block a user