From 8032c7bdac0aafa1ebe897478c3538f85730705d Mon Sep 17 00:00:00 2001 From: Stefan Froemken Date: Thu, 5 Dec 2024 13:21:50 +0100 Subject: [PATCH] Remove readonly to be compatible with PHP 8.1 --- Classes/Command/NotifySearchEngineCommand.php | 6 +++--- Classes/Domain/Repository/StackRepository.php | 2 +- .../EventListener/RespectPagesWithNoIndexEventListener.php | 2 +- Classes/Hook/DataHandlerHook.php | 2 +- Classes/Notifier/SearchEngineNotifier.php | 2 +- 5 files changed, 7 insertions(+), 7 deletions(-) diff --git a/Classes/Command/NotifySearchEngineCommand.php b/Classes/Command/NotifySearchEngineCommand.php index 9d3564d..9c71802 100644 --- a/Classes/Command/NotifySearchEngineCommand.php +++ b/Classes/Command/NotifySearchEngineCommand.php @@ -32,9 +32,9 @@ class NotifySearchEngineCommand extends Command * Will be called by DI, so please don't add extbase classes with inject methods here. */ public function __construct( - readonly protected SearchEngineNotifier $searchEngineNotifier, - readonly protected StackRepository $stackRepository, - readonly protected LoggerInterface $logger, + protected SearchEngineNotifier $searchEngineNotifier, + protected StackRepository $stackRepository, + protected LoggerInterface $logger, ) { parent::__construct(); } diff --git a/Classes/Domain/Repository/StackRepository.php b/Classes/Domain/Repository/StackRepository.php index 7c41a38..f73228c 100644 --- a/Classes/Domain/Repository/StackRepository.php +++ b/Classes/Domain/Repository/StackRepository.php @@ -16,7 +16,7 @@ /** * Repository to collect records from table "tx_indexnow_stack" */ -readonly class StackRepository +class StackRepository { private const TABLE_NAME = 'tx_indexnow_stack'; diff --git a/Classes/EventListener/RespectPagesWithNoIndexEventListener.php b/Classes/EventListener/RespectPagesWithNoIndexEventListener.php index c1dd790..15936a5 100644 --- a/Classes/EventListener/RespectPagesWithNoIndexEventListener.php +++ b/Classes/EventListener/RespectPagesWithNoIndexEventListener.php @@ -16,7 +16,7 @@ /** * Prevent informing IndexNow about pages with activated no_index property. */ -readonly class RespectPagesWithNoIndexEventListener +class RespectPagesWithNoIndexEventListener { public function __invoke(ModifyPageUidEvent $modifyPageUidEvent): void { diff --git a/Classes/Hook/DataHandlerHook.php b/Classes/Hook/DataHandlerHook.php index 8d2731c..0f60dcc 100644 --- a/Classes/Hook/DataHandlerHook.php +++ b/Classes/Hook/DataHandlerHook.php @@ -32,7 +32,7 @@ /** * Hook into DataHandler to submit a re-index request to indexnow.org */ -readonly class DataHandlerHook +class DataHandlerHook { public function __construct( protected ExtConf $extConf, diff --git a/Classes/Notifier/SearchEngineNotifier.php b/Classes/Notifier/SearchEngineNotifier.php index 0d608bf..fc568a3 100644 --- a/Classes/Notifier/SearchEngineNotifier.php +++ b/Classes/Notifier/SearchEngineNotifier.php @@ -19,7 +19,7 @@ /** * Service to communicate with the search engine */ -readonly class SearchEngineNotifier +class SearchEngineNotifier { public function __construct( protected RequestFactory $requestFactory,