From 6954b4e8aef0e5d46f8558c90edcf27bb01b4724 Mon Sep 17 00:00:00 2001 From: Nicolas Grekas Date: Thu, 10 Jul 2025 09:12:18 +0200 Subject: [PATCH] CS fixes --- Factory/PsrHttpFactory.php | 2 +- Factory/UploadedFile.php | 2 +- Tests/Factory/PsrHttpFactoryTest.php | 14 +++++++------- 3 files changed, 9 insertions(+), 9 deletions(-) diff --git a/Factory/PsrHttpFactory.php b/Factory/PsrHttpFactory.php index 7c824fd..a4a07ad 100644 --- a/Factory/PsrHttpFactory.php +++ b/Factory/PsrHttpFactory.php @@ -50,7 +50,7 @@ public function __construct( $psr17Factory = match (true) { class_exists(DiscoveryPsr17Factory::class) => new DiscoveryPsr17Factory(), class_exists(NyholmPsr17Factory::class) => new NyholmPsr17Factory(), - default => throw new \LogicException(sprintf('You cannot use the "%s" as no PSR-17 factories have been provided. Try running "composer require php-http/discovery psr/http-factory-implementation:*".', self::class)), + default => throw new \LogicException(\sprintf('You cannot use the "%s" as no PSR-17 factories have been provided. Try running "composer require php-http/discovery psr/http-factory-implementation:*".', self::class)), }; $serverRequestFactory ??= $psr17Factory; diff --git a/Factory/UploadedFile.php b/Factory/UploadedFile.php index f680dd5..34d4058 100644 --- a/Factory/UploadedFile.php +++ b/Factory/UploadedFile.php @@ -59,7 +59,7 @@ public function move(string $directory, ?string $name = null): File try { $this->psrUploadedFile->moveTo((string) $target); } catch (\RuntimeException $e) { - throw new FileException(sprintf('Could not move the file "%s" to "%s" (%s).', $this->getPathname(), $target, $e->getMessage()), 0, $e); + throw new FileException(\sprintf('Could not move the file "%s" to "%s" (%s).', $this->getPathname(), $target, $e->getMessage()), 0, $e); } @chmod($target, 0666 & ~umask()); diff --git a/Tests/Factory/PsrHttpFactoryTest.php b/Tests/Factory/PsrHttpFactoryTest.php index 0c41221..850e84d 100644 --- a/Tests/Factory/PsrHttpFactoryTest.php +++ b/Tests/Factory/PsrHttpFactoryTest.php @@ -219,14 +219,14 @@ public function testUploadErrNoFile() [], [], [ - 'f1' => $file, - 'f2' => ['name' => null, 'type' => null, 'tmp_name' => null, 'error' => \UPLOAD_ERR_NO_FILE, 'size' => 0], - ], + 'f1' => $file, + 'f2' => ['name' => null, 'type' => null, 'tmp_name' => null, 'error' => \UPLOAD_ERR_NO_FILE, 'size' => 0], + ], [ - 'REQUEST_METHOD' => 'POST', - 'HTTP_HOST' => 'dunglas.fr', - 'HTTP_X_SYMFONY' => '2.8', - ], + 'REQUEST_METHOD' => 'POST', + 'HTTP_HOST' => 'dunglas.fr', + 'HTTP_X_SYMFONY' => '2.8', + ], 'Content' ); pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy