From 14d4246db5b081c7429fda576dc40cbf633685f9 Mon Sep 17 00:00:00 2001 From: Roberto Butti Date: Fri, 8 Dec 2023 19:10:02 +0100 Subject: [PATCH] Upgrading stuff per PHP CS Fixer - Adding static_lambda' => false in the php cs fixer cong - eliminating PHP_CS_FIXER_IGNORE_ENV (no more needed) --- .php-cs-fixer.php | 1 + composer.json | 4 ++-- src/Storyblok/ApiException.php | 4 +--- src/Storyblok/Client.php | 2 -- 4 files changed, 4 insertions(+), 7 deletions(-) diff --git a/.php-cs-fixer.php b/.php-cs-fixer.php index c132135..5048bcc 100644 --- a/.php-cs-fixer.php +++ b/.php-cs-fixer.php @@ -27,6 +27,7 @@ 'concat_space' => ['spacing' => 'one'], 'visibility_required' => false, 'no_null_property_initialization' => false, + 'static_lambda' => false, ]); $config->setFinder($finder); diff --git a/composer.json b/composer.json index 2ee5a43..4adaf52 100644 --- a/composer.json +++ b/composer.json @@ -52,8 +52,8 @@ "test-ci": "pest --ci", "phpstan": "phpstan analyse", "test-coverage": "pest --coverage", - "format": "PHP_CS_FIXER_IGNORE_ENV=1 php-cs-fixer fix --allow-risky=yes --using-cache=no", - "cs": "PHP_CS_FIXER_IGNORE_ENV=1 php-cs-fixer fix --dry-run --using-cache=no", + "format": "php-cs-fixer fix --allow-risky=yes --using-cache=no", + "cs": "php-cs-fixer fix --dry-run --using-cache=no", "all-check": [ "@format", "@phpstan", diff --git a/src/Storyblok/ApiException.php b/src/Storyblok/ApiException.php index 30706b5..b1e6bb0 100644 --- a/src/Storyblok/ApiException.php +++ b/src/Storyblok/ApiException.php @@ -5,6 +5,4 @@ /** * Storyblok Exception. */ -class ApiException extends \Exception -{ -} +class ApiException extends \Exception {} diff --git a/src/Storyblok/Client.php b/src/Storyblok/Client.php index 90afd4c..cb12660 100644 --- a/src/Storyblok/Client.php +++ b/src/Storyblok/Client.php @@ -206,8 +206,6 @@ public function getApiParameters() * * @param string $driver Driver * @param array $options Path for file cache - * - * @return \Storyblok\Client */ public function setCache($driver, $options = []): self {