mirror of
https://github.com/Part-DB/Part-DB-server.git
synced 2025-06-22 09:53:35 +02:00
Fixed some inspection issues.
This commit is contained in:
parent
eef26f7ae6
commit
639829f5c5
97 changed files with 305 additions and 185 deletions
|
@ -25,6 +25,7 @@ namespace App\Repository;
|
|||
|
||||
use App\Entity\Base\AbstractDBElement;
|
||||
use Doctrine\ORM\EntityRepository;
|
||||
use ReflectionClass;
|
||||
|
||||
class DBElementRepository extends EntityRepository
|
||||
{
|
||||
|
@ -68,7 +69,7 @@ class DBElementRepository extends EntityRepository
|
|||
|
||||
protected function setField(AbstractDBElement $element, string $field, int $new_value): void
|
||||
{
|
||||
$reflection = new \ReflectionClass(get_class($element));
|
||||
$reflection = new ReflectionClass(get_class($element));
|
||||
$property = $reflection->getProperty($field);
|
||||
$property->setAccessible(true);
|
||||
$property->setValue($element, $new_value);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue