mirror of
https://gitlab.com/Chill-Projet/chill-bundles.git
synced 2025-08-21 15:13:50 +00:00
apply rector rules after merging master branch
This commit is contained in:
@@ -18,7 +18,7 @@ use Chill\PersonBundle\Repository\Person\PersonCenterHistoryRepository;
|
||||
class PersonMoveCenterHistoryHandler implements PersonMoveSqlHandlerInterface
|
||||
{
|
||||
public function __construct(
|
||||
private PersonCenterHistoryRepository $centerHistoryRepository,
|
||||
private readonly PersonCenterHistoryRepository $centerHistoryRepository,
|
||||
) {}
|
||||
|
||||
public function supports(string $className, string $field): bool
|
||||
|
@@ -36,9 +36,9 @@ use function in_array;
|
||||
class PersonMove
|
||||
{
|
||||
public function __construct(
|
||||
private EntityManagerInterface $em,
|
||||
private PersonMoveManager $personMoveManager,
|
||||
private EventDispatcherInterface $eventDispatcher
|
||||
private readonly EntityManagerInterface $em,
|
||||
private readonly PersonMoveManager $personMoveManager,
|
||||
private readonly EventDispatcherInterface $eventDispatcher
|
||||
) {}
|
||||
|
||||
/**
|
||||
@@ -95,7 +95,7 @@ class PersonMove
|
||||
$sql,
|
||||
['to' => $to->getId(), 'original_action' => 'move']
|
||||
);
|
||||
$this->eventDispatcher->dispatch(ActionEvent::DELETE, $event);
|
||||
$this->eventDispatcher->dispatch($event, ActionEvent::DELETE);
|
||||
$sqls = array_merge($sqls, $event->getPreSql(), [$event->getSqlStatement()], $event->getPostSql());
|
||||
} else {
|
||||
$sqls = array_merge($sqls, $this->createMoveSQLs($metadata, $from, $to, $field));
|
||||
|
@@ -19,12 +19,11 @@ class PersonMoveManager
|
||||
/**
|
||||
* @var iterable<PersonMoveSqlHandlerInterface>
|
||||
*/
|
||||
private iterable $handlers,
|
||||
private readonly iterable $handlers,
|
||||
) {}
|
||||
|
||||
/**
|
||||
* @param class-string $className
|
||||
* @param string $field
|
||||
* @return bool
|
||||
*/
|
||||
public function hasHandler(string $className, string $field): bool
|
||||
|
Reference in New Issue
Block a user