From c8fa87d03d4991085e9f9c4371e87e1920f18e3d Mon Sep 17 00:00:00 2001 From: Michel Roux Date: Sun, 10 Nov 2024 16:01:21 +0100 Subject: [PATCH] style: :art: remove rule on php cs --- .php-cs-fixer.dist.php | 1 - composer.json | 2 +- composer.lock | 2 +- lib/Core/EpisodeAction/EpisodeActionReader.php | 3 ++- .../GPodderSync/Core/EpisodeAction/EpisodeActionReader.php | 4 +++- stubs/OCA/GPodderSync/Core/PodcastData/PodcastData.php | 6 ++++-- .../GPodderSync/Db/EpisodeAction/EpisodeActionMapper.php | 1 + .../GPodderSync/Db/EpisodeAction/EpisodeActionWriter.php | 2 ++ 8 files changed, 14 insertions(+), 7 deletions(-) diff --git a/.php-cs-fixer.dist.php b/.php-cs-fixer.dist.php index 273bc13..74670ab 100644 --- a/.php-cs-fixer.dist.php +++ b/.php-cs-fixer.dist.php @@ -13,7 +13,6 @@ class MyConfig extends Config $rules = parent::getRules(); $rules['@PhpCsFixer'] = true; $rules['curly_braces_position']['classes_opening_brace'] = 'next_line_unless_newline_at_signature_end'; - $rules['phpdoc_separation'] = false; $rules['phpdoc_to_comment'] = false; return $rules; } diff --git a/composer.json b/composer.json index 31c1f22..eda97df 100644 --- a/composer.json +++ b/composer.json @@ -17,9 +17,9 @@ }, "require-dev": { "nextcloud/ocp": "^30.0.2", + "roave/security-advisories": "dev-latest", "nextcloud/coding-standard": "^1.3.2", "rector/rector": "^1.2.10", - "roave/security-advisories": "dev-latest", "vimeo/psalm": "^5.26.1" }, "config": { diff --git a/composer.lock b/composer.lock index e09232a..d3ceb6a 100644 --- a/composer.lock +++ b/composer.lock @@ -4,7 +4,7 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "1b3b97dd0074d6decb4ce7f570ef7d4e", + "content-hash": "f63004cd7dd2ace25dfec89f0ea70b76", "packages": [], "packages-dev": [ { diff --git a/lib/Core/EpisodeAction/EpisodeActionReader.php b/lib/Core/EpisodeAction/EpisodeActionReader.php index cc5364d..4e1310d 100644 --- a/lib/Core/EpisodeAction/EpisodeActionReader.php +++ b/lib/Core/EpisodeAction/EpisodeActionReader.php @@ -20,7 +20,8 @@ class EpisodeActionReader extends CoreEpisodeActionReader * Specs : https://github.com/Podcast-Standards-Project/PSP-1-Podcast-RSS-Specification/blob/main/README.md. * * @return EpisodeActionExtraData[] - * @throws \Exception if the XML data could not be parsed + * + * @throws \Exception if the XML data could not be parsed */ public function parseRssXml(string $xmlString, ?int $fetchedAtUnix = null): array { $episodes = []; diff --git a/stubs/OCA/GPodderSync/Core/EpisodeAction/EpisodeActionReader.php b/stubs/OCA/GPodderSync/Core/EpisodeAction/EpisodeActionReader.php index de85137..a593d78 100644 --- a/stubs/OCA/GPodderSync/Core/EpisodeAction/EpisodeActionReader.php +++ b/stubs/OCA/GPodderSync/Core/EpisodeAction/EpisodeActionReader.php @@ -7,8 +7,10 @@ namespace OCA\GPodderSync\Core\EpisodeAction; class EpisodeActionReader { /** - * @param array $episodeActionsArray [] + * @param array $episodeActionsArray [] + * * @return EpisodeAction[] + * * @throws \InvalidArgumentException */ public function fromArray(array $episodeActionsArray) {} diff --git a/stubs/OCA/GPodderSync/Core/PodcastData/PodcastData.php b/stubs/OCA/GPodderSync/Core/PodcastData/PodcastData.php index 6eb8dba..a4d318d 100644 --- a/stubs/OCA/GPodderSync/Core/PodcastData/PodcastData.php +++ b/stubs/OCA/GPodderSync/Core/PodcastData/PodcastData.php @@ -29,7 +29,8 @@ class PodcastData implements \JsonSerializable /** * @return PodcastData - * @throws \Exception if the XML data could not be parsed + * + * @throws \Exception if the XML data could not be parsed */ public static function parseRssXml(string $xmlString, ?int $fetchedAtUnix = null) {} @@ -81,7 +82,8 @@ class PodcastData implements \JsonSerializable public function jsonSerialize(): mixed {} /** - * @param PodcastDataType $data + * @param PodcastDataType $data + * * @return PodcastData */ public static function fromArray(array $data) {} diff --git a/stubs/OCA/GPodderSync/Db/EpisodeAction/EpisodeActionMapper.php b/stubs/OCA/GPodderSync/Db/EpisodeAction/EpisodeActionMapper.php index 06a67a1..e44ebb5 100644 --- a/stubs/OCA/GPodderSync/Db/EpisodeAction/EpisodeActionMapper.php +++ b/stubs/OCA/GPodderSync/Db/EpisodeAction/EpisodeActionMapper.php @@ -21,6 +21,7 @@ class EpisodeActionMapper extends QBMapper /** * @return EpisodeActionEntity[] + * * @throws Exception */ public function findAll(int $sinceTimestamp, string $userId) {} diff --git a/stubs/OCA/GPodderSync/Db/EpisodeAction/EpisodeActionWriter.php b/stubs/OCA/GPodderSync/Db/EpisodeAction/EpisodeActionWriter.php index 2d3aa82..911609b 100644 --- a/stubs/OCA/GPodderSync/Db/EpisodeAction/EpisodeActionWriter.php +++ b/stubs/OCA/GPodderSync/Db/EpisodeAction/EpisodeActionWriter.php @@ -14,12 +14,14 @@ class EpisodeActionWriter /** * @return EpisodeActionEntity + * * @throws Exception */ public function save(EpisodeActionEntity $episodeActionEntity) {} /** * @return EpisodeActionEntity + * * @throws Exception */ public function update(EpisodeActionEntity $episodeActionEntity) {}