diff --git a/Classes/AvatarProvider/GravatarProvider.php b/Classes/AvatarProvider/GravatarProvider.php index b25a72d5..54b3a9f1 100644 --- a/Classes/AvatarProvider/GravatarProvider.php +++ b/Classes/AvatarProvider/GravatarProvider.php @@ -27,20 +27,9 @@ class GravatarProvider implements AvatarProviderInterface, SingletonInterface { - /** - * @var GravatarUriBuilderInterface - */ - private $gravatarUriBuilder; - - /** - * @var AvatarResourceResolverInterface - */ - private $avatarResourceResolver; - - /** - * @var bool - */ - private $proxyGravatarImage; + private GravatarUriBuilderInterface $gravatarUriBuilder; + private AvatarResourceResolverInterface $avatarResourceResolver; + private bool $proxyGravatarImage; final public function __construct() { diff --git a/Classes/Controller/CommentController.php b/Classes/Controller/CommentController.php index 0463afdb..ed026aab 100644 --- a/Classes/Controller/CommentController.php +++ b/Classes/Controller/CommentController.php @@ -11,7 +11,6 @@ namespace T3G\AgencyPack\Blog\Controller; use Psr\Http\Message\ResponseInterface; -use T3G\AgencyPack\Blog\Domain\Model\Comment; use T3G\AgencyPack\Blog\Domain\Model\Post; use T3G\AgencyPack\Blog\Domain\Repository\PostRepository; use T3G\AgencyPack\Blog\Service\CacheService; @@ -20,50 +19,22 @@ class CommentController extends ActionController { - /** - * @var PostRepository - */ - protected $postRepository; - - /** - * @var CommentService - */ - protected $commentService; - - /** - * @var CacheService - */ - protected $blogCacheService; - - /** - * @param PostRepository $postRepository - */ - public function injectPostRepository(PostRepository $postRepository): void - { + protected PostRepository $postRepository; + protected CommentService $commentService; + protected CacheService $cacheService; + + public function __construct( + PostRepository $postRepository, + CommentService $commentService, + CacheService $cacheService + ) { $this->postRepository = $postRepository; - } - - /** - * @param \T3G\AgencyPack\Blog\Service\CommentService $commentService - */ - public function injectCommentService(CommentService $commentService): void - { $this->commentService = $commentService; - } - - /** - * @param \T3G\AgencyPack\Blog\Service\CacheService $cacheService - */ - public function injectBlogCacheService(CacheService $cacheService): void - { - $this->blogCacheService = $cacheService; + $this->cacheService = $cacheService; } /** * Show comment form. - * - * @throws \TYPO3\CMS\Extbase\Configuration\Exception\InvalidConfigurationTypeException - * @throws \TYPO3\CMS\Extbase\Persistence\Exception\InvalidQueryException */ public function formAction(): ResponseInterface { @@ -71,18 +42,13 @@ public function formAction(): ResponseInterface return $this->htmlResponse(); } - /** - * @throws \TYPO3\CMS\Core\Context\Exception\AspectNotFoundException - * @throws \TYPO3\CMS\Extbase\Configuration\Exception\InvalidConfigurationTypeException - * @throws \TYPO3\CMS\Extbase\Persistence\Exception\InvalidQueryException - */ public function commentsAction(): ResponseInterface { $post = $this->postRepository->findCurrentPost(); if ($post instanceof Post) { $comments = $this->commentService->getCommentsByPost($post); foreach ($comments as $comment) { - $this->blogCacheService->addTagToPage('tx_blog_comment_' . $comment->getUid()); + $this->cacheService->addTagToPage('tx_blog_comment_' . $comment->getUid()); } $this->view->assign('comments', $comments); $this->view->assign('post', $post); diff --git a/Classes/Controller/WidgetController.php b/Classes/Controller/WidgetController.php index d3277d01..ad7adc97 100644 --- a/Classes/Controller/WidgetController.php +++ b/Classes/Controller/WidgetController.php @@ -22,69 +22,24 @@ class WidgetController extends ActionController { - /** - * @var CategoryRepository - */ - protected $categoryRepository; - - /** - * @var TagRepository - */ - protected $tagRepository; - - /** - * @var PostRepository - */ - protected $postRepository; - - /** - * @var CommentRepository - */ - protected $commentRepository; - - /** - * @var CacheService - */ - protected $blogCacheService; - - /** - * @param CategoryRepository $categoryRepository - */ - public function injectCategoryRepository(CategoryRepository $categoryRepository): void - { + protected CategoryRepository $categoryRepository; + protected TagRepository $tagRepository; + protected PostRepository $postRepository; + protected CommentRepository $commentRepository; + protected CacheService $cacheService; + + public function __construct( + CategoryRepository $categoryRepository, + TagRepository $tagRepository, + PostRepository $postRepository, + CommentRepository $commentRepository, + CacheService $cacheService + ) { $this->categoryRepository = $categoryRepository; - } - - /** - * @param TagRepository $tagRepository - */ - public function injectTagRepository(TagRepository $tagRepository): void - { $this->tagRepository = $tagRepository; - } - - /** - * @param PostRepository $postRepository - */ - public function injectPostRepository(PostRepository $postRepository): void - { $this->postRepository = $postRepository; - } - - /** - * @param CommentRepository $commentRepository - */ - public function injectCommentRepository(CommentRepository $commentRepository): void - { $this->commentRepository = $commentRepository; - } - - /** - * @param \T3G\AgencyPack\Blog\Service\CacheService $cacheService - */ - public function injectBlogCacheService(CacheService $cacheService): void - { - $this->blogCacheService = $cacheService; + $this->cacheService = $cacheService; } public function categoriesAction(): ResponseInterface @@ -98,7 +53,7 @@ public function categoriesAction(): ResponseInterface $this->view->assign('categories', $categories); $this->view->assign('currentCategory', $currentCategory); foreach ($categories as $category) { - $this->blogCacheService->addTagToPage('tx_blog_category_' . $category->getUid()); + $this->cacheService->addTagToPage('tx_blog_category_' . $category->getUid()); } return $this->htmlResponse(); } @@ -136,18 +91,13 @@ public function tagsAction(): ResponseInterface } unset($tagReference); foreach ($tags as $tag) { - $this->blogCacheService->addTagToPage('tx_blog_tag_' . (int)$tag['uid']); + $this->cacheService->addTagToPage('tx_blog_tag_' . (int)$tag['uid']); } $this->view->assign('tags', $tags); $this->view->assign('currentTag', $currentTag); return $this->htmlResponse(); } - /** - * @throws \TYPO3\CMS\Core\Context\Exception\AspectNotFoundException - * @throws \TYPO3\CMS\Extbase\Configuration\Exception\InvalidConfigurationTypeException - * @throws \TYPO3\CMS\Extbase\Persistence\Exception\InvalidQueryException - */ public function recentPostsAction(): ResponseInterface { $limit = (int)($this->settings['widgets']['recentposts']['limit'] ?? 0); @@ -157,16 +107,12 @@ public function recentPostsAction(): ResponseInterface : $this->postRepository->findAll(); foreach ($posts as $post) { - $this->blogCacheService->addTagsForPost($post); + $this->cacheService->addTagsForPost($post); } $this->view->assign('posts', $posts); return $this->htmlResponse(); } - /** - * @throws \TYPO3\CMS\Core\Context\Exception\AspectNotFoundException - * @throws \TYPO3\CMS\Extbase\Persistence\Exception\InvalidQueryException - */ public function commentsAction(): ResponseInterface { $limit = (int)($this->settings['widgets']['comments']['limit'] ?? 5); @@ -174,14 +120,11 @@ public function commentsAction(): ResponseInterface $comments = $this->commentRepository->findActiveComments($limit, $blogSetup); $this->view->assign('comments', $comments); foreach ($comments as $comment) { - $this->blogCacheService->addTagToPage('tx_blog_comment_' . $comment->getUid()); + $this->cacheService->addTagToPage('tx_blog_comment_' . $comment->getUid()); } return $this->htmlResponse(); } - /** - * @throws \TYPO3\CMS\Extbase\Configuration\Exception\InvalidConfigurationTypeException - */ public function archiveAction(): ResponseInterface { $posts = $this->postRepository->findMonthsAndYearsWithPosts(); diff --git a/Classes/DataTransferObject/AvatarResource.php b/Classes/DataTransferObject/AvatarResource.php index a985a345..f9dd53e8 100644 --- a/Classes/DataTransferObject/AvatarResource.php +++ b/Classes/DataTransferObject/AvatarResource.php @@ -15,8 +15,6 @@ interface AvatarResource { public function getUri(): UriInterface; - public function getContentType(): string; - public function getContent(): string; } diff --git a/Classes/DataTransferObject/Gravatar.php b/Classes/DataTransferObject/Gravatar.php index 8bbbf678..376c4dee 100644 --- a/Classes/DataTransferObject/Gravatar.php +++ b/Classes/DataTransferObject/Gravatar.php @@ -14,20 +14,9 @@ class Gravatar implements AvatarResource { - /** - * @var UriInterface - */ - private $uri; - - /** - * @var string - */ - private $contentType; - - /** - * @var string - */ - private $content; + private UriInterface $uri; + private string $contentType; + private string $content; public function __construct(UriInterface $uri, string $contentType, string $content) { diff --git a/Classes/DataTransferObject/PostRepositoryDemand.php b/Classes/DataTransferObject/PostRepositoryDemand.php index c4294e66..09033a7a 100644 --- a/Classes/DataTransferObject/PostRepositoryDemand.php +++ b/Classes/DataTransferObject/PostRepositoryDemand.php @@ -19,37 +19,26 @@ class PostRepositoryDemand /** * @var int[] */ - protected $posts = []; + protected array $posts = []; /** * @var Category[] */ - protected $categories = []; - - /** - * @var string - */ - protected $categoriesConjunction = Constants::REPOSITORY_CONJUNCTION_AND; + protected array $categories = []; + protected string $categoriesConjunction = Constants::REPOSITORY_CONJUNCTION_AND; /** * @var Tag[] */ - protected $tags = []; - - /** - * @var string - */ - protected $tagsConjunction = Constants::REPOSITORY_CONJUNCTION_AND; + protected array $tags = []; + protected string $tagsConjunction = Constants::REPOSITORY_CONJUNCTION_AND; /** * @var string[] */ - protected $ordering = []; + protected array $ordering = []; - /** - * @var int - */ - protected $limit = 0; + protected int $limit = 0; /** * @return int[] @@ -100,9 +89,6 @@ public function removeCategory(Category $category): self return $this; } - /** - * @return string - */ public function getCategoriesConjunction(): string { return $this->categoriesConjunction; @@ -140,9 +126,6 @@ public function removeTag(Tag $tag): self return $this; } - /** - * @return string - */ public function getTagsConjunction(): string { return $this->tagsConjunction; diff --git a/Classes/Domain/Factory/CommentFormFactory.php b/Classes/Domain/Factory/CommentFormFactory.php index 9f4b19fa..093ec3ed 100644 --- a/Classes/Domain/Factory/CommentFormFactory.php +++ b/Classes/Domain/Factory/CommentFormFactory.php @@ -34,10 +34,6 @@ class CommentFormFactory extends AbstractFormFactory * Build a FormDefinition. * This example build a FormDefinition manually, * so $configuration and $prototypeName are unused. - * - * @param array $configuration - * @param string $prototypeName - * @return FormDefinition */ public function build(array $configuration, string $prototypeName = null): FormDefinition { diff --git a/Classes/Domain/Repository/AuthorRepository.php b/Classes/Domain/Repository/AuthorRepository.php index 167db40f..70253705 100644 --- a/Classes/Domain/Repository/AuthorRepository.php +++ b/Classes/Domain/Repository/AuthorRepository.php @@ -18,11 +18,6 @@ */ class AuthorRepository extends Repository { - /** - * Initializes the repository. - * - * @throws \InvalidArgumentException - */ public function initializeObject(): void { $this->defaultOrderings = [ diff --git a/Classes/ExpressionLanguage/BlogVariableProvider.php b/Classes/ExpressionLanguage/BlogVariableProvider.php index 8dd2b4e7..9ef3ec64 100644 --- a/Classes/ExpressionLanguage/BlogVariableProvider.php +++ b/Classes/ExpressionLanguage/BlogVariableProvider.php @@ -17,9 +17,6 @@ */ class BlogVariableProvider { - /** - * @return bool - */ public function isPost(): bool { $page = $GLOBALS['TSFE']->page ?? []; @@ -29,9 +26,6 @@ public function isPost(): bool return false; } - /** - * @return bool - */ public function isPage(): bool { $page = $GLOBALS['TSFE']->page ?? []; diff --git a/Classes/Factory/PostRepositoryDemandFactory.php b/Classes/Factory/PostRepositoryDemandFactory.php index 2fd04476..77cf43fb 100644 --- a/Classes/Factory/PostRepositoryDemandFactory.php +++ b/Classes/Factory/PostRepositoryDemandFactory.php @@ -18,15 +18,8 @@ class PostRepositoryDemandFactory { - /** - * @var CategoryRepository - */ - private $categoryRepository; - - /** - * @var TagRepository - */ - private $tagRepository; + private CategoryRepository $categoryRepository; + private TagRepository $tagRepository; public function __construct( CategoryRepository $categoryRepository, diff --git a/Classes/Notification/AbstractNotification.php b/Classes/Notification/AbstractNotification.php index af06b4f6..fc0a3d24 100644 --- a/Classes/Notification/AbstractNotification.php +++ b/Classes/Notification/AbstractNotification.php @@ -12,27 +12,10 @@ abstract class AbstractNotification implements NotificationInterface { - /** - * @var string - */ - protected $title; + protected string $title; + protected string $message; + protected array $data; - /** - * @var string - */ - protected $message; - - /** - * @var array - */ - protected $data; - - /** - * AbstractNotification constructor. - * @param string $title - * @param string $message - * @param array $data - */ public function __construct(string $title = '', string $message = '', array $data = []) { $this->title = $title; @@ -40,63 +23,39 @@ public function __construct(string $title = '', string $message = '', array $dat $this->data = $data; } - /** - * @return string - */ public function getTitle(): string { return $this->title; } - /** - * @param string $title - * @return AbstractNotification - */ public function setTitle(string $title): self { $this->title = $title; return $this; } - /** - * @return string - */ public function getMessage(): string { return $this->message; } - /** - * @param string $message - * @return AbstractNotification - */ public function setMessage(string $message): self { $this->message = $message; return $this; } - /** - * @return array - */ public function getData(): array { return $this->data; } - /** - * @param array $data - * @return AbstractNotification - */ public function setData(array $data): self { $this->data = $data; return $this; } - /** - * @return string - */ public function getNotificationId(): string { return static::class; diff --git a/Classes/Notification/CommentAddedNotification.php b/Classes/Notification/CommentAddedNotification.php index bec4974c..a28e8700 100644 --- a/Classes/Notification/CommentAddedNotification.php +++ b/Classes/Notification/CommentAddedNotification.php @@ -18,9 +18,6 @@ class CommentAddedNotification extends AbstractNotification { - /** - * @return string - */ public function getTitle(): string { /** @var Post $post */ @@ -28,12 +25,6 @@ public function getTitle(): string return sprintf((string)LocalizationUtility::translate('emails.CommentAddedNotification.subject', 'blog'), $post->getTitle()); } - /** - * @return string - * @throws \RuntimeException - * @throws \InvalidArgumentException - * @throws \TYPO3\CMS\Extbase\Mvc\Exception\InvalidExtensionNameException - */ public function getMessage(): string { /** @var Comment $comment */ diff --git a/Classes/Notification/NotificationInterface.php b/Classes/Notification/NotificationInterface.php index a1f6d658..b4fa5675 100644 --- a/Classes/Notification/NotificationInterface.php +++ b/Classes/Notification/NotificationInterface.php @@ -12,29 +12,8 @@ interface NotificationInterface { - /** - * @return string - */ public function getNotificationId(): string; - - /** - * Get the title of the message - * - * @return string - */ public function getTitle(): string; - - /** - * Get the message of the notification - * - * @return string - */ public function getMessage(): string; - - /** - * Get additional data of notification - * - * @return array - */ public function getData(): array; } diff --git a/Classes/Notification/NotificationManager.php b/Classes/Notification/NotificationManager.php index 28169d77..9a82c928 100644 --- a/Classes/Notification/NotificationManager.php +++ b/Classes/Notification/NotificationManager.php @@ -15,10 +15,7 @@ class NotificationManager { - /** - * @var array - */ - protected $visitorsRegistry = []; + protected array $visitorsRegistry = []; public function __construct() { @@ -33,10 +30,6 @@ public function __construct() } } - /** - * @param NotificationInterface $notification - * @throws \InvalidArgumentException - */ public function notify(NotificationInterface $notification): void { $notificationId = $notification->getNotificationId(); diff --git a/Classes/Pagination/BlogPagination.php b/Classes/Pagination/BlogPagination.php index c9ff9ead..7b6a2e70 100644 --- a/Classes/Pagination/BlogPagination.php +++ b/Classes/Pagination/BlogPagination.php @@ -117,17 +117,11 @@ public function getAllPageNumbers(): array return range($this->getFirstPageNumber(), $this->getLastPageNumber()); } - /** - * @return int - */ public function getDisplayRangeStart(): int { return $this->displayRangeStart; } - /** - * @return int - */ public function getDisplayRangeEnd(): int { return $this->displayRangeEnd; @@ -151,25 +145,16 @@ public function hasMorePages(): bool return $this->getDisplayRangeEnd() < $this->getLastPageNumber(); } - /** - * @return int - */ public function getMaximumNumberOfLinks(): int { return $this->maximumNumberOfLinks; } - /** - * @return PaginatorInterface - */ public function getPaginator(): PaginatorInterface { return $this->paginator; } - /** - * @return iterable - */ public function getPaginatedItems(): iterable { return $this->paginator->getPaginatedItems(); diff --git a/Classes/Service/MetaTagService.php b/Classes/Service/MetaTagService.php index cbd2b64d..09ce8698 100644 --- a/Classes/Service/MetaTagService.php +++ b/Classes/Service/MetaTagService.php @@ -19,18 +19,9 @@ */ class MetaTagService { - // Page Title public const META_TITLE = 'title'; - - // Description public const META_DESCRIPTION = 'description'; - /** - * @param string $type - * @param string $value - * - * @throws \InvalidArgumentException - */ public static function set(string $type, string $value): void { switch ($type) { @@ -45,10 +36,6 @@ public static function set(string $type, string $value): void } } - /** - * @param string $value - * @return void - */ protected static function setTitle(string $value): void { $provider = GeneralUtility::makeInstance(BlogTitleTagProvider::class); @@ -59,10 +46,6 @@ protected static function setTitle(string $value): void $twitterTitleManager->addProperty('twitter:title', $value); } - /** - * @param string $value - * @return void - */ protected static function setDescription(string $value): void { $descriptionManager = GeneralUtility::makeInstance(MetaTagManagerRegistry::class)->getManagerForProperty('description'); diff --git a/Classes/TitleTagProvider/BlogTitleTagProvider.php b/Classes/TitleTagProvider/BlogTitleTagProvider.php index 3e5e7cff..d6f0e8d7 100644 --- a/Classes/TitleTagProvider/BlogTitleTagProvider.php +++ b/Classes/TitleTagProvider/BlogTitleTagProvider.php @@ -13,9 +13,6 @@ class BlogTitleTagProvider extends AbstractPageTitleProvider { - /** - * @param string $title - */ public function setTitle(string $title): void { $this->title = $title; diff --git a/Classes/Updates/AbstractUpdate.php b/Classes/Updates/AbstractUpdate.php index 38ba3427..0f564f6f 100644 --- a/Classes/Updates/AbstractUpdate.php +++ b/Classes/Updates/AbstractUpdate.php @@ -26,20 +26,13 @@ abstract class AbstractUpdate const CONDITION_AND = 'AND'; const CONDITION_OR = 'OR'; - /** - * @var string - */ - protected $title = ''; - - /** - * @var string - */ - protected $description = ''; + protected string $title = ''; + protected string $description = ''; /** * @var Connection[] */ - protected $connection = []; + protected array $connection = []; public function getIdentifier(): string { diff --git a/Classes/Updates/AuthorSlugUpdate.php b/Classes/Updates/AuthorSlugUpdate.php index 6dd0d237..8144fd4d 100644 --- a/Classes/Updates/AuthorSlugUpdate.php +++ b/Classes/Updates/AuthorSlugUpdate.php @@ -17,15 +17,8 @@ final class AuthorSlugUpdate extends AbstractUpdate implements UpgradeWizardInterface { - /** - * @var string - */ - protected $title = 'EXT:blog: Generate Path-Segments for Authors'; - - /** - * @var string - */ - protected $table = 'tx_blog_domain_model_author'; + protected string $title = 'EXT:blog: Generate Path-Segments for Authors'; + protected string $table = 'tx_blog_domain_model_author'; public function updateNecessary(): bool { diff --git a/Classes/Updates/AvatarProviderUpdate.php b/Classes/Updates/AvatarProviderUpdate.php index 5801a1f4..be3cf10c 100644 --- a/Classes/Updates/AvatarProviderUpdate.php +++ b/Classes/Updates/AvatarProviderUpdate.php @@ -15,15 +15,8 @@ final class AvatarProviderUpdate extends AbstractUpdate implements UpgradeWizardInterface { - /** - * @var string - */ - protected $title = 'EXT:blog: Migrate AvatarProvider'; - - /** - * @var string - */ - protected $table = 'tx_blog_domain_model_author'; + protected string $title = 'EXT:blog: Migrate AvatarProvider'; + protected string $table = 'tx_blog_domain_model_author'; public function updateNecessary(): bool { diff --git a/Classes/Updates/CategorySlugUpdate.php b/Classes/Updates/CategorySlugUpdate.php index c2b1e36d..a05bcd64 100644 --- a/Classes/Updates/CategorySlugUpdate.php +++ b/Classes/Updates/CategorySlugUpdate.php @@ -17,15 +17,8 @@ final class CategorySlugUpdate extends AbstractUpdate implements UpgradeWizardInterface { - /** - * @var string - */ - protected $title = 'EXT:blog: Generate Path-Segments for Categories'; - - /** - * @var string - */ - protected $table = 'sys_category'; + protected string $title = 'EXT:blog: Generate Path-Segments for Categories'; + protected string $table = 'sys_category'; public function updateNecessary(): bool { diff --git a/Classes/Updates/CategoryTypeUpdate.php b/Classes/Updates/CategoryTypeUpdate.php index 69983aef..fadb21fe 100644 --- a/Classes/Updates/CategoryTypeUpdate.php +++ b/Classes/Updates/CategoryTypeUpdate.php @@ -15,15 +15,8 @@ final class CategoryTypeUpdate extends AbstractUpdate implements UpgradeWizardInterface { - /** - * @var string - */ - protected $title = 'EXT:blog: Use Blog-Type for Categories'; - - /** - * @var string - */ - protected $table = 'sys_category'; + protected string $title = 'EXT:blog: Use Blog-Type for Categories'; + protected string $table = 'sys_category'; public function updateNecessary(): bool { diff --git a/Classes/Updates/CommentStatusUpdate.php b/Classes/Updates/CommentStatusUpdate.php index 46ee1a04..7071dc5a 100644 --- a/Classes/Updates/CommentStatusUpdate.php +++ b/Classes/Updates/CommentStatusUpdate.php @@ -14,15 +14,8 @@ final class CommentStatusUpdate extends AbstractUpdate implements UpgradeWizardInterface { - /** - * @var string - */ - protected $title = 'EXT:blog: Migrate Comment Status'; - - /** - * @var string - */ - protected $table = 'tx_blog_domain_model_comment'; + protected string $title = 'EXT:blog: Migrate Comment Status'; + protected string $table = 'tx_blog_domain_model_comment'; public function updateNecessary(): bool { diff --git a/Classes/Updates/Criteria/AbstractCriteria.php b/Classes/Updates/Criteria/AbstractCriteria.php index d4d8c6cf..6ab302e4 100644 --- a/Classes/Updates/Criteria/AbstractCriteria.php +++ b/Classes/Updates/Criteria/AbstractCriteria.php @@ -14,15 +14,8 @@ abstract class AbstractCriteria { - /** - * @var QueryBuilder - */ - protected $queryBuilder; - - /** - * @var string - */ - protected $field; + protected QueryBuilder $queryBuilder; + protected string $field; public function __construct(QueryBuilder $queryBuilder, string $field) { diff --git a/Classes/Updates/Criteria/EqualIntCriteria.php b/Classes/Updates/Criteria/EqualIntCriteria.php index 674cbe30..00d60713 100644 --- a/Classes/Updates/Criteria/EqualIntCriteria.php +++ b/Classes/Updates/Criteria/EqualIntCriteria.php @@ -14,10 +14,7 @@ class EqualIntCriteria extends AbstractCriteria implements CriteriaInterface { - /** - * @var int - */ - protected $value; + protected int $value; public function setValue(int $value): self { diff --git a/Classes/Updates/Criteria/EqualStringCriteria.php b/Classes/Updates/Criteria/EqualStringCriteria.php index f77104ee..f7ca8517 100644 --- a/Classes/Updates/Criteria/EqualStringCriteria.php +++ b/Classes/Updates/Criteria/EqualStringCriteria.php @@ -14,10 +14,7 @@ class EqualStringCriteria extends AbstractCriteria implements CriteriaInterface { - /** - * @var string - */ - protected $value; + protected string $value; public function setValue(string $value): self { diff --git a/Classes/Updates/Criteria/InCriteria.php b/Classes/Updates/Criteria/InCriteria.php index cdd7915e..dec64e51 100644 --- a/Classes/Updates/Criteria/InCriteria.php +++ b/Classes/Updates/Criteria/InCriteria.php @@ -14,10 +14,7 @@ class InCriteria extends AbstractCriteria implements CriteriaInterface { - /** - * @var array - */ - protected $values; + protected array $values; public function setValues(array $values): self { diff --git a/Classes/Updates/Criteria/NotEqualIntCriteria.php b/Classes/Updates/Criteria/NotEqualIntCriteria.php index 14d25231..98d7586d 100644 --- a/Classes/Updates/Criteria/NotEqualIntCriteria.php +++ b/Classes/Updates/Criteria/NotEqualIntCriteria.php @@ -14,10 +14,7 @@ class NotEqualIntCriteria extends AbstractCriteria implements CriteriaInterface { - /** - * @var int - */ - protected $value; + protected int $value; public function setValue(int $value): self { diff --git a/Classes/Updates/DatabaseMonthYearUpdate.php b/Classes/Updates/DatabaseMonthYearUpdate.php index 9f6198cd..0e8519a1 100644 --- a/Classes/Updates/DatabaseMonthYearUpdate.php +++ b/Classes/Updates/DatabaseMonthYearUpdate.php @@ -15,15 +15,8 @@ final class DatabaseMonthYearUpdate extends AbstractUpdate implements UpgradeWizardInterface { - /** - * @var string - */ - protected $title = 'EXT:blog: Set new month and year fields for existing blog posts'; - - /** - * @var string - */ - protected $table = 'pages'; + protected string $title = 'EXT:blog: Set new month and year fields for existing blog posts'; + protected string $table = 'pages'; public function updateNecessary(): bool { diff --git a/Classes/Updates/DatabasePublishDateUpdate.php b/Classes/Updates/DatabasePublishDateUpdate.php index e4c00cd5..10c72806 100644 --- a/Classes/Updates/DatabasePublishDateUpdate.php +++ b/Classes/Updates/DatabasePublishDateUpdate.php @@ -15,15 +15,8 @@ final class DatabasePublishDateUpdate extends AbstractUpdate implements UpgradeWizardInterface { - /** - * @var string - */ - protected $title = 'EXT:blog: Set publish date fields to crdate for existing blog posts'; - - /** - * @var string - */ - protected $table = 'pages'; + protected string $title = 'EXT:blog: Set publish date fields to crdate for existing blog posts'; + protected string $table = 'pages'; public function updateNecessary(): bool { diff --git a/Classes/Updates/FeaturedImageUpdate.php b/Classes/Updates/FeaturedImageUpdate.php index 30b02706..b2b25196 100644 --- a/Classes/Updates/FeaturedImageUpdate.php +++ b/Classes/Updates/FeaturedImageUpdate.php @@ -15,10 +15,7 @@ final class FeaturedImageUpdate extends AbstractUpdate implements UpgradeWizardInterface, RepeatableInterface { - /** - * @var string - */ - protected $title = 'EXT:blog: Featured Image Update'; + protected string $title = 'EXT:blog: Featured Image Update'; public function updateNecessary(): bool { diff --git a/Classes/Updates/TagSlugUpdate.php b/Classes/Updates/TagSlugUpdate.php index 7111301e..b241eafd 100644 --- a/Classes/Updates/TagSlugUpdate.php +++ b/Classes/Updates/TagSlugUpdate.php @@ -17,15 +17,8 @@ final class TagSlugUpdate extends AbstractUpdate implements UpgradeWizardInterface { - /** - * @var string - */ - protected $title = 'EXT:blog: Generate Path-Segments for Tags'; - - /** - * @var string - */ - protected $table = 'tx_blog_domain_model_tag'; + protected string $title = 'EXT:blog: Generate Path-Segments for Tags'; + protected string $table = 'tx_blog_domain_model_tag'; public function updateNecessary(): bool { diff --git a/Classes/Utility/ArchiveUtility.php b/Classes/Utility/ArchiveUtility.php index edb297ce..304b5873 100644 --- a/Classes/Utility/ArchiveUtility.php +++ b/Classes/Utility/ArchiveUtility.php @@ -27,10 +27,6 @@ class ArchiveUtility * ] * ... * ] - * - * @param array $data - * @return array - * @throws \Exception */ public static function extractDataFromPosts(array $data): array {