Skip to content

Commit b4566a9

Browse files
authored
Correct type of SimpleXMLElement properties
Fixes phpstan/phpstan#2910
1 parent 5b7bb9c commit b4566a9

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/Type/Php/SimpleXMLElementClassPropertyReflectionExtension.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ public function hasProperty(ClassReflection $classReflection, string $propertyNa
1919

2020
public function getProperty(ClassReflection $classReflection, string $propertyName): PropertyReflection
2121
{
22-
return new SimpleXMLElementProperty($classReflection, new ObjectType('SimpleXMLElement'));
22+
return new SimpleXMLElementProperty($classReflection, new ObjectType($classReflection->getName()));
2323
}
2424

2525
}

0 commit comments

Comments
 (0)