diff --git a/composer.json b/composer.json index fbcbe56f..3c14bf30 100644 --- a/composer.json +++ b/composer.json @@ -9,17 +9,17 @@ "Audit" ], "require": { - "php": "^8.1", + "php": "^8.0", "doctrine/collections": "^1.8 || ^2.0", "doctrine/dbal": "^3.6", "doctrine/event-manager": "^1.2 || ^2.0", "doctrine/orm": "^2.14 || ^3.0", "doctrine/persistence": "^3.0", "psr/clock": "^1.0", - "symfony/config": "^6.4 || ^7.1", - "symfony/dependency-injection": "^6.4 || ^7.1", - "symfony/http-kernel": "^6.4 || ^7.1", - "symfony/security-core": "^6.4 || ^7.1", + "symfony/config": "^5.4 || ^6.2 || ^7.0", + "symfony/dependency-injection": "^5.4 || ^6.2 || ^7.0", + "symfony/http-kernel": "^5.4 || ^6.2 || ^7.0", + "symfony/security-core": "^5.4 || ^6.2 || ^7.0", "twig/twig": "^3.0" }, "require-dev": { @@ -38,15 +38,15 @@ "psalm/plugin-phpunit": "^0.18", "psalm/plugin-symfony": "^5.0", "rector/rector": "^1.1", - "symfony/browser-kit": "^6.4 || ^7.1", - "symfony/cache": "^6.4 || ^7.1", - "symfony/filesystem": "^6.4 || ^7.1", - "symfony/framework-bundle": "^6.4 || ^7.1", - "symfony/http-foundation": "^6.4 || ^7.1", - "symfony/phpunit-bridge": "^6.4 || ^7.1", - "symfony/security-bundle": "^6.4 || ^7.1", - "symfony/twig-bundle": "^6.4 || ^7.1", - "symfony/var-dumper": "^6.4 || ^7.1", + "symfony/browser-kit": "^5.4 || ^6.2 || ^7.0", + "symfony/cache": "^5.4 || ^6.2 || ^7.0", + "symfony/filesystem": "^5.4 || ^6.2 || ^7.0", + "symfony/framework-bundle": "^5.4 || ^6.2 || ^7.0", + "symfony/http-foundation": "^5.4 || ^6.2 || ^7.0", + "symfony/phpunit-bridge": "^6.2", + "symfony/security-bundle": "^5.4 || ^6.2 || ^7.0", + "symfony/twig-bundle": "^5.4 || ^6.2 || ^7.0", + "symfony/var-dumper": "^5.4 || ^6.2 || ^7.0", "vimeo/psalm": "^5.7" }, "conflict": { diff --git a/src/Action/CompareAction.php b/src/Action/CompareAction.php index 5c82e8ed..4041fd5f 100644 --- a/src/Action/CompareAction.php +++ b/src/Action/CompareAction.php @@ -21,8 +21,8 @@ final class CompareAction { public function __construct( - private readonly Environment $twig, - private readonly AuditReader $auditReader, + private Environment $twig, + private AuditReader $auditReader, ) { } diff --git a/src/Action/IndexAction.php b/src/Action/IndexAction.php index d2d7b11a..0cc119f1 100644 --- a/src/Action/IndexAction.php +++ b/src/Action/IndexAction.php @@ -20,8 +20,8 @@ final class IndexAction { public function __construct( - private readonly Environment $twig, - private readonly AuditReader $auditReader, + private Environment $twig, + private AuditReader $auditReader, ) { } diff --git a/src/Action/ViewDetailAction.php b/src/Action/ViewDetailAction.php index 777c53fc..3cdc0437 100644 --- a/src/Action/ViewDetailAction.php +++ b/src/Action/ViewDetailAction.php @@ -21,8 +21,8 @@ final class ViewDetailAction { public function __construct( - private readonly Environment $twig, - private readonly AuditReader $auditReader, + private Environment $twig, + private AuditReader $auditReader, ) { } diff --git a/src/Action/ViewEntityAction.php b/src/Action/ViewEntityAction.php index c80f5eb7..da2bf386 100644 --- a/src/Action/ViewEntityAction.php +++ b/src/Action/ViewEntityAction.php @@ -20,8 +20,8 @@ final class ViewEntityAction { public function __construct( - private readonly Environment $twig, - private readonly AuditReader $auditReader, + private Environment $twig, + private AuditReader $auditReader, ) { } diff --git a/src/Action/ViewRevisionAction.php b/src/Action/ViewRevisionAction.php index 5f4c168c..a9102e97 100644 --- a/src/Action/ViewRevisionAction.php +++ b/src/Action/ViewRevisionAction.php @@ -22,8 +22,8 @@ final class ViewRevisionAction { public function __construct( - private readonly Environment $twig, - private readonly AuditReader $auditReader, + private Environment $twig, + private AuditReader $auditReader, ) { } diff --git a/src/AuditManager.php b/src/AuditManager.php index 0acf0a33..98b88f33 100644 --- a/src/AuditManager.php +++ b/src/AuditManager.php @@ -26,11 +26,11 @@ */ class AuditManager { - private readonly MetadataFactory $metadataFactory; + private MetadataFactory $metadataFactory; public function __construct( - private readonly AuditConfiguration $config, - private readonly ?ClockInterface $clock = null, + private AuditConfiguration $config, + private ?ClockInterface $clock = null, ) { $this->metadataFactory = $config->createMetadataFactory(); } diff --git a/src/ChangedEntity.php b/src/ChangedEntity.php index a5061ac3..f48e04ba 100644 --- a/src/ChangedEntity.php +++ b/src/ChangedEntity.php @@ -25,10 +25,10 @@ class ChangedEntity * @phpstan-param T $entity */ public function __construct( - private readonly string $className, - private readonly array $id, - private readonly string $revType, - private readonly object $entity, + private string $className, + private array $id, + private string $revType, + private object $entity, ) { } diff --git a/src/DeferredChangedManyToManyEntityRevisionToPersist.php b/src/DeferredChangedManyToManyEntityRevisionToPersist.php index 5e4f008a..56eac1cc 100644 --- a/src/DeferredChangedManyToManyEntityRevisionToPersist.php +++ b/src/DeferredChangedManyToManyEntityRevisionToPersist.php @@ -28,12 +28,12 @@ final class DeferredChangedManyToManyEntityRevisionToPersist * @param ClassMetadata $targetClass */ public function __construct( - private readonly object $entity, - private readonly string $revType, - private readonly array $entityData, - private readonly array|ManyToManyOwningSideMapping $assoc, - private readonly ClassMetadata $class, - private readonly ClassMetadata $targetClass, + private object $entity, + private string $revType, + private array $entityData, + private array|ManyToManyOwningSideMapping $assoc, + private ClassMetadata $class, + private ClassMetadata $targetClass, ) { } diff --git a/src/EventListener/CacheListener.php b/src/EventListener/CacheListener.php index 5745db3f..ff0b218d 100644 --- a/src/EventListener/CacheListener.php +++ b/src/EventListener/CacheListener.php @@ -22,7 +22,7 @@ */ final class CacheListener implements EventSubscriber { - public function __construct(private readonly AuditReader $auditReader) + public function __construct(private AuditReader $auditReader) { } diff --git a/src/Revision.php b/src/Revision.php index eda368a5..ad42d3e9 100644 --- a/src/Revision.php +++ b/src/Revision.php @@ -23,8 +23,8 @@ class Revision */ public function __construct( private $rev, - private readonly \DateTime $timestamp, - private readonly ?string $username, + private \DateTime $timestamp, + private ?string $username, ) { } diff --git a/tests/ClockTest.php b/tests/ClockTest.php index 3e6feebc..22cb02e6 100644 --- a/tests/ClockTest.php +++ b/tests/ClockTest.php @@ -50,7 +50,7 @@ public function testFixedClockIsUsed(): void protected function getClock(): ClockInterface { return new class($this->getFixedTime()) implements ClockInterface { - public function __construct(private readonly \DateTimeImmutable $now) + public function __construct(private \DateTimeImmutable $now) { }