Fixed phpstan analysis issues and bad code that showed up with phpstan 2.0

This commit is contained in:
Jan Böhmer 2024-12-28 22:31:04 +01:00
parent a273acbecd
commit 946032a101
42 changed files with 98 additions and 85 deletions

View file

@ -151,7 +151,7 @@ class StructuralDBElementRepository extends AttachmentContainingDBElementReposit
}
if (null === $entity) {
$class = $this->getClassName();
/** @var AbstractStructuralDBElement $entity */
/** @var TEntityClass $entity */
$entity = new $class;
$entity->setName($name);
$entity->setParent($parent);
@ -265,7 +265,7 @@ class StructuralDBElementRepository extends AttachmentContainingDBElementReposit
}
$class = $this->getClassName();
/** @var AbstractStructuralDBElement $entity */
/** @var TEntityClass $entity */
$entity = new $class;
$entity->setName($name);