Skip to content

Commit

Permalink
DOMDocumentPlugin: Bugfix blacklisted property type
Browse files Browse the repository at this point in the history
  • Loading branch information
jnvsor committed Aug 23, 2024
1 parent ff3dd3b commit 2824ed7
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 2 deletions.
Binary file modified build/kint.phar
Binary file not shown.
3 changes: 1 addition & 2 deletions src/Parser/DOMDocumentPlugin.php
Original file line number Diff line number Diff line change
Expand Up @@ -346,12 +346,11 @@ protected function parseProperty(InstanceValue $o, string $prop, DOMNode &$var):
if (!isset($var->{$prop})) {
$base_obj->type = 'null';
} elseif (isset(self::$blacklist[$prop])) {
$b = new InstanceValue($base_obj->name, \get_class($var), \spl_object_hash($var), \spl_object_id($var));
$b = new InstanceValue($base_obj->name, self::$blacklist[$prop], \spl_object_hash($var->{$prop}), \spl_object_id($var->{$prop}));
$b->transplant($base_obj);
$base_obj = $b;

$base_obj->hints[] = 'blacklist';
$base_obj->classname = self::$blacklist[$prop];
} else {
$parser = $this->getParser();
if ('attributes' === $prop && $parser->getDepthLimit() && $parser->getDepthLimit() - 2 < $base_obj->depth) {
Expand Down

0 comments on commit 2824ed7

Please sign in to comment.